M lib/dhall/ast.rb => lib/dhall/ast.rb +0 -4
@@ 41,10 41,6 @@ module Dhall
end
end
- def <<(other)
- Operator::TextConcatenate.new(lhs: self, rhs: other)
- end
-
def concat(other)
Operator::ListConcatenate.new(lhs: self, rhs: other)
end
M lib/dhall/normalize.rb => lib/dhall/normalize.rb +1 -8
@@ 199,14 199,7 @@ module Dhall
class TextConcatenate
def normalize
- normalized = super
- if normalized.lhs == Text.new(value: "")
- normalized.rhs
- elsif normalized.rhs == Text.new(value: "")
- normalized.lhs
- else
- normalized.lhs << normalized.rhs
- end
+ TextLiteral.for(lhs, rhs).normalize
end
end