Skip to content

fix: ids are now reset correctly for the next match statement - #111

Merged
BowenFu merged 1 commit into
BowenFu:mainfrom
d-u-d-e:fix/reset
Oct 14, 2026
Merged

BowenFu merged 1 commit into
BowenFu:mainfrom
d-u-d-e:fix/reset

Conversation

@d-u-d-e

@d-u-d-e d-u-d-e commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Hello Bowen,
I discovered this elegant library, so I decided to take a look at it because I'd like to use it on my own projects.
I think there's an issue with matchPatterns: processId is called on a PatternPairs type, which in turn calls processIdImpl on PatternTraits for a PatternPair, which has an empty processIdImpl as the primary template. Thus processId(pattern, 0, IdProcess::kCANCEL) has no effect. I added a test case that covers this issue. Without the changes, the second match throws. I don't think this should be expected behavior (but maybe I'm wrong).

Do you agree on this? If you'd like me to open an issue let me know.
Hope you can find some time to look at this PR. Thank you!

@BowenFu

BowenFu commented Oct 14, 2026

Copy link
Copy Markdown
Owner

@d-u-d-e thanks for your contribution. LGTM

@BowenFu
BowenFu merged commit 5341c45 into BowenFu:main Oct 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants