-
Notifications
You must be signed in to change notification settings - Fork 13.3k
add diagnostics for E0387 #27605
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 diagnostics for E0387 #27605
Conversation
Welcome back! |
I'd like to see some tips for cases where the function definition is not owned by the user too. Something that hints the usage of interior mutability (std::cell) would be nice. r+ as-is is also fine by me |
Thanks! I'm not exactly firing on all cylinders, but hoping to get things done here and there :-). Good point on the use of cell, that actually hadn't crossed my mind. I'll add it in. |
Added info about cell types! |
|
||
``` | ||
fn mutable() { | ||
let x = std::cell::Cell::new(0u32); |
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.
nit: just use import std::cell::Cell;
at the top, long paths look ugly inline
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 :)
@bors r+ rollup |
📌 Commit f041966 has been approved by |
…arth As title :-) Part of rust-lang#24407. r? @Manishearth
As title :-) Part of rust-lang#24407. r? @Manishearth
As title :-)
Part of #24407.
r? @Manishearth