You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are three node patterns, all very similar except that an OR group has different amount of branches. I expect them to all return the same thing but what actually happens is that depending on the amount of branches the output changes:
One branch: As expected (but also not very useful)
Two branches: The first capture is wrapped in an array and is empty when the optional part matches
Three branches: When the optional doesn't match it has 4 captures but the first is not wrapped, and when the optional does match it only return 2 captures (with the expected shape even)
There seems to be some state leak. While I'm getting better at writing node patterns, understanding what is going on here is far beyond me. I think this pattern should be valid but maybe I'm misunderstanding something?
The text was updated successfully, but these errors were encountered:
It's a bit much, so I'll just start with the testcase:
There are three node patterns, all very similar except that an OR group has different amount of branches. I expect them to all return the same thing but what actually happens is that depending on the amount of branches the output changes:
There seems to be some state leak. While I'm getting better at writing node patterns, understanding what is going on here is far beyond me. I think this pattern should be valid but maybe I'm misunderstanding something?
The text was updated successfully, but these errors were encountered: