-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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 debug_assert and debug_assert_eq macros #13789
Conversation
If you grep for |
Updated |
Are we testing things with both |
If not, we should just turn on |
|
I also switched some `assert!` calls over to `debug_assert!`. Closes rust-lang#12049. RFC: 0015-assert
This should be good to go. cc @pcwalton |
I switched the `assert!` calls in `RefCell` over to `debug_assert!`. There are probably other instances that should be converted as well, but I couldn't think of any off the top of my head. RFC: 0015-assert
feat: show only missing variant suggestion for enums in patterns completion and bump them in list too Fixes rust-lang#12438 ### Points to help in review: - This PR can be reviewed commit wise, first commit is about bumping enum variant completions up in the list of completions and second commit is about only showing enum variants which are not complete - I am calculating missing variants in analysis.rs by firstly locating the enum and then comparing each of it's variant's name and checking if arm string already contains that name, this is kinda hacky but I didn't want to implement complete missing_arms assist here as that would have been too bulky to run on each completion cycle ( if we can improve this somehow would appreciate some inputs on it ) ### Output: https://user-images.githubusercontent.com/49019259/208245540-57d7321b-b275-477e-bef0-b3a1ff8b7040.mov Relevant Zulip Discussion: https://rust-lang.zulipchat.com/#narrow/stream/185405-t-compiler.2Frust-analyzer/topic/Issue.20.2312438
This addresses rust-lang#13099 for the manual_split_once test, using the str_splitn lint. changelog: [str_splitn]: Updated str_splitn to use multipart_suggestions where appropriate
I switched the
assert!
calls inRefCell
over todebug_assert!
.There are probably other instances that should be converted as well, but
I couldn't think of any off the top of my head.
RFC: 0015-assert