Closed icze closed 4 years ago
That is a bug. The problem is that the star
-rule always succeeds. In this case, however, star<A,B>
could leave remnants of A
even though B
didn't match. The problem goes away if you use star<seq<A,B>>
but, of course, that should not be necessary.
I'll try to find a fix...
Thanks for the fast answer. In the meanwhile I will integrate your workaround into abnf2pegtl
and see if I get my large grammar run ...
We have identified a couple of potential solutions, however at the moment they all seem somewhat involved. We will take a bit of time to see how best to proceed. Hopefully the work-around with additional seq<>
rules allows you to continue for now.
I committed a fix in the master branch. Can you try if it works for you? Do you need the fix to be backported to the 2.x branch?
Thanks for the fix. I tested it with the example and it works as expected. Implementing my large grammar I found another issue #199.
According to 2.x: It depends on when you are planning to release 3.0.0 and if the master is already somehow stable. From my side, I'm integrating your library the first time in our software and I'm able to wait 2-3 month for the 3.0.0.
Thanks a lot for your great work.
Add: When I'm thinking more about the merging, the workaround is sufficient for me on 2.x
Thanks for checking. For now, we will continue to improve the fix in the master branch, but ultimately I'll try and backport it, if possible, when it stabilized for those users still stuck on C++11.
About the release date of the 3.0.0: Colin and me talked about it yesterday and once this issue is fully resolved (there might be a few more corner cases that we need to discuss), we will release 3.0.0. It is already stable for quite some time now and any additional (API-changing) features will have to wait for a future 4.x.
Hallo,
first of all thanks for your fantastic library, especially the parse tree and ABNF parts are quite helpful. I'm new on PEGTL and currently implementing a large grammar with PEGTL 2.8.1 and Visual Studio 16.4.6. Doing this some problems are arising. Therefore here a reduced example:
Here the output:
Now I'm wondering why "entry_list" has empty content but "entry" contains
Can anybody give me a hint? Regards Ingo