I want to keep a standalone parser in my repo, to make it easy to use without any dependencies. But even rebuilding exactly the same grammar produces a different parse table, which makes git diff unhappy. I presume this is because set() is unordered.
To Reproduce
The simplest possible grammar: an empty start rule, start:. Then compile it twice and compare the output, diff =(python -m lark.tools.standalone a.g) =(python -m lark.tools.standalone a.g).
Describe the bug
I want to keep a standalone parser in my repo, to make it easy to use without any dependencies. But even rebuilding exactly the same grammar produces a different parse table, which makes git diff unhappy. I presume this is because
set()
is unordered.To Reproduce
The simplest possible grammar: an empty start rule,
start:
. Then compile it twice and compare the output,diff =(python -m lark.tools.standalone a.g) =(python -m lark.tools.standalone a.g)
.(I cut off some irrelevant parts)