lib/antelope/generation/constructor.rb in antelope-0.1.8 vs lib/antelope/generation/constructor.rb in antelope-0.1.9
- old
+ new
@@ -61,10 +61,11 @@
state.rules.select { |x| x.position.zero? }.each do |rule|
production = rule.production.clone
production.items = []
current_state = state
+ old_state = state
production.label.from = state
production.label.to = state.transitions[rule.left.name]
rule.right.each_with_index do |part, pos|
@@ -76,9 +77,10 @@
new_item.to = transition
end
production.items << new_item
+ old_state = current_state
current_state = transition
end
productions << production
end