Class: Dhallish::Types::List

Inherits:
Object
  • Object
show all
Defined in:
lib/types.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(type) ⇒ List

Returns a new instance of List.



46
47
48
# File 'lib/types.rb', line 46

def initialize(type)
	@type = type
end

Instance Attribute Details

#typeObject

Type of List elements



45
46
47
# File 'lib/types.rb', line 45

def type
  @type
end

Instance Method Details

#==(otype) ⇒ Object



50
# File 'lib/types.rb', line 50

def ==(otype) otype.is_a? List and otype.type == @type end

#to_sObject



51
# File 'lib/types.rb', line 51

def to_s() "List #{@type.to_s}" end