-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Rename begin_panic
to panic_with_payload
#144902
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
base: master
Are you sure you want to change the base?
Rename begin_panic
to panic_with_payload
#144902
Conversation
rustbot has assigned @Mark-Simulacrum. Use |
Some changes occurred to the CTFE machinery This PR modifies Some changes occurred to constck cc @fee1-dead Some changes occurred in src/tools/clippy cc @rust-lang/clippy |
This comment has been minimized.
This comment has been minimized.
1fc546b
to
8d38e92
Compare
This comment has been minimized.
This comment has been minimized.
// types other than str. Check to enforce that only str can be used in | ||
// const-eval. | ||
|
||
// const-eval of the `begin_panic` fn assumes the argument is `&str` | ||
// const-eval of the `panic_with_payload` fn assumes the argument is `&str` | ||
if tcx.is_lang_item(callee, LangItem::BeginPanic) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the lang item should be renamed too to match the new function name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does it needs FCP?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, that is not necessary. Lang items are purely internal implementation details. They change all the time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done! Could you take a look and resolve it if so
8d38e92
to
5d10eb5
Compare
rust-analyzer is developed in its own repository. If possible, consider making this change to rust-lang/rust-analyzer instead. cc @rust-lang/rust-analyzer The rustc-dev-guide subtree was changed. If this PR only touches the dev guide consider submitting a PR directly to rust-lang/rustc-dev-guide otherwise thank you for updating the dev guide with your changes. |
According to message above would it be reasonable to move rust-analyzer changes into it's repo? or it's fine like this |
This comment has been minimized.
This comment has been minimized.
5d10eb5
to
98d2ad4
Compare
98d2ad4
to
22e6d2b
Compare
This was little bit discussed here #t-libs > `begin_panic` renaming @ 💬, so I guess this is fine name
Also as far as I can say it's safe to rename because of lang item, correct me here if I'm wrong
Part of #116005