Method: Cel::ListType#initialize

Defined in:
lib/cel/ast/types.rb

#initialize(type_list) ⇒ ListType

Returns a new instance of ListType.



52
53
54
55
56
# File 'lib/cel/ast/types.rb', line 52

def initialize(type_list)
  super(:list)
  @type_list = type_list
  @element_type = @type_list.empty? ? TYPES[:any] : @type_list.sample.type
end