nitcc: remove reduction even in non-dangling S/R conflict
authorJean Privat <jean@pryen.org>
Wed, 9 Sep 2015 09:26:46 +0000 (05:26 -0400)
committerJean Privat <jean@pryen.org>
Wed, 9 Sep 2015 09:26:46 +0000 (05:26 -0400)
Signed-off-by: Jean Privat <jean@pryen.org>

contrib/nitcc/src/grammar.nit

index fc10a98..0a10beb 100644 (file)
@@ -1038,6 +1038,7 @@ class LRState
                                        print "SHIFT/REDUCE Conflict on state {self.number} {self.name} for token {t}:"
                                        print "\treduce: {ri}"
                                        for i in guarded_shift[t] do print "\tshift:  {i}"
+                                       removed_reduces.add t
                                end
                        end
                end