-
Notifications
You must be signed in to change notification settings - Fork 0
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
Provide more information about the RFC2229 and migration information #1
base: master
Are you sure you want to change the base?
Conversation
roxelo
commented
Jul 1, 2021
- Should I be linking to the rust reference instead? All the information in one place would make sense
- How much info is needed to be provided about migration?
- Should we be adding info about filling bugs and closure profiling here?
}); // Closure captured px.0 which is not Send | ||
``` | ||
|
||
## Capture Precision |
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.
not this section
As for all edition changes, an automatic migration is available. | ||
If you would like to be warned of semantics change that may impact your code, you can [use the lint](https://doc.rust-lang.org/rustc/lints/levels.html) `disjoint_capture_migrations`. The lint is also supported with [cargo fix](https://doc.rust-lang.org/cargo/commands/cargo-fix.html) to automatically migrate your code. | ||
|
||
The migration fix involves adding `let _ = &a;`, where `a` is the variable that needs to be fully captures, inside the closure to force the entire |
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.
full captured
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.
entire variable to be captured as before
If you would like to be warned of semantics change that may impact your code, you can [use the lint](https://doc.rust-lang.org/rustc/lints/levels.html) `disjoint_capture_migrations`. The lint is also supported with [cargo fix](https://doc.rust-lang.org/cargo/commands/cargo-fix.html) to automatically migrate your code. | ||
|
||
The migration fix involves adding `let _ = &a;`, where `a` is the variable that needs to be fully captures, inside the closure to force the entire | ||
struct to be captured as before. |
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 meant variable here
cee12c4
to
cbde8bb
Compare
Co-authored-by: Ryan Levick <[email protected]> Co-authored-by: Eric Huss <[email protected]>
updates to rfc2229 info Pr