-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
bugSomething isn't workingSomething isn't workingtests neededUnit tests are required for all public APIUnit tests are required for all public API
Description
Currently the L53 of list parser passes the hard-coded unused attribute for the underlying parser. This leads to surprising result at runtime, where the content of the RHS is silently omitted even if the RHS has some explicit attribute.
x4/include/iris/x4/operator/list.hpp
Lines 47 to 55 in 9de1d0c
| if (!detail::parse_into_container(this->left, first, last, ctx, x4::assume_container(attr))) { | |
| return false; | |
| } | |
| It last_parse_it = first; | |
| while ( | |
| this->right.parse(last_parse_it, last, ctx, unused) && | |
| detail::parse_into_container(this->left, last_parse_it, last, ctx, x4::assume_container(attr)) | |
| ) { |
This looks like a bug to me, but fixing this would be a breaking change. We should re-check the unit tests.
A workaround is to rewrite this:
body % delimto this:
body >> *(delim >> body)but I think the current behavior is very awkward in the first place.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingtests neededUnit tests are required for all public APIUnit tests are required for all public API