lib/code/node/decimal.rb in code-ruby-0.6.4 vs lib/code/node/decimal.rb in code-ruby-0.6.5
- old
+ new
@@ -4,12 +4,10 @@
class Node
class Decimal < Node
def initialize(parsed)
@decimal = parsed.delete(:decimal)
- if parsed.key?(:exponent)
- @exponent = Node::Statement.new(parsed.delete(:exponent))
- end
+ @exponent = Node::Statement.new(parsed.delete(:exponent)) if parsed.key?(:exponent)
super(parsed)
end
def evaluate(**args)