-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add fuel to match checking #9528
Labels
A-pattern
pattern handling related things
E-medium
S-actionable
Someone could pick this issue up and work on it right now
Comments
matklad
added
E-medium
S-actionable
Someone could pick this issue up and work on it right now
labels
Jul 8, 2021
Workin on it :) |
GuillaumeGomez
added a commit
to GuillaumeGomez/rust
that referenced
this issue
Mar 3, 2024
…limit.rs, r=Nadrieril Add new `pattern_complexity` attribute to add possibility to limit and check recursion in pattern matching Needed for rust-lang/rust-analyzer#9528. This PR adds a new attribute only available when running rust testsuite called `pattern_complexity` which allows to set the maximum recursion for the pattern matching. It is quite useful to ensure the complexity doesn't grow, like in `tests/ui/pattern/usefulness/issue-118437-exponential-time-on-diagonal-match.rs`. r? `@Nadrieril`
rust-timer
added a commit
to rust-lang-ci/rust
that referenced
this issue
Mar 3, 2024
Rollup merge of rust-lang#121917 - GuillaumeGomez:pattern-complexity_limit.rs, r=Nadrieril Add new `pattern_complexity` attribute to add possibility to limit and check recursion in pattern matching Needed for rust-lang/rust-analyzer#9528. This PR adds a new attribute only available when running rust testsuite called `pattern_complexity` which allows to set the maximum recursion for the pattern matching. It is quite useful to ensure the complexity doesn't grow, like in `tests/ui/pattern/usefulness/issue-118437-exponential-time-on-diagonal-match.rs`. r? `@Nadrieril`
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-pattern
pattern handling related things
E-medium
S-actionable
Someone could pick this issue up and work on it right now
https://niedzejkob.p4.team/rust-np/
Exhaustiveness checking can be arbitrary slow, we need to have an ability to give up after some time.
The text was updated successfully, but these errors were encountered: