parser: do not lose location in case of replacement
[nit.git] / src / parser / parser_nodes.nit
index 47a74a3..bb273c9 100644 (file)
@@ -103,7 +103,7 @@ abstract class Prod
        do
                super
                assert n isa Prod
-               n.location = location
+               if n._location == null then n._location = _location
        end
 end