# File lib/algebrick/type.rb, line 23 def initialize(name, &definition) super &definition @name = name end
# File lib/algebrick/type.rb, line 36 def ==(other) raise NotImplementedError end
# File lib/algebrick/type.rb, line 40 def be_kind_of(type) raise NotImplementedError end
# File lib/algebrick/type.rb, line 48 def inspect to_s end
# File lib/algebrick/type.rb, line 52 def match(value, *cases) Type! value, self super value, *cases end
# File lib/algebrick/type.rb, line 28 def name super || @name || nil end
# File lib/algebrick/type.rb, line 32 def to_m(*args) raise NotImplementedError end
# File lib/algebrick/type.rb, line 44 def to_s raise NotImplementedError end