dlang-community / Pegged

A Parsing Expression Grammar (PEG) module, using the D programming language.
533 stars 66 forks source link

Issue with optional #259

Open Aphexus opened 6 years ago

Aphexus commented 6 years ago

Rule < A B? B

Will fail because of the order.

Rule < A B B?

will pass.

It might be beneficial to detect this type of bug.

Note that it could be more complicated(like the recursion issues).