-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
confusing error message around trait object bound #54779
Comments
Assigning myself to bookmark. |
This seems to be a persistent ergonomics wart where traits get evaluated to |
I just want to note that the use of That is, I get the exact same diagnostic even if I add an explicit This is relevant because it means that if that feature is a red herring, then this bug may be relevant to the 2018 edition. |
discussed with @nikomatsakis . We agreed this is not a blocker for 2018 edition. Tagging with NLL-deferred so it does not clog up our triage process. |
I forgot to actual test how migration-mode (enabled for the 2018 edition) compares to Current (nightly) 2018 edition output (play):
Current (nightly) output with
|
As for this week's triage, tagging this as P-medium priority. |
Since |
The example without The error message isn't the same as migrate mode, but is on-par in terms of information (pointing out that the anonymous lifetime doesn't live as long as |
…askrgr Rollup of 5 pull requests Successful merges: - rust-lang#96154 (Expand core::hint::unreachable_unchecked() docs) - rust-lang#96615 (Add a regression test for rust-lang#54779) - rust-lang#96982 (fix clippy expect_fun_call) - rust-lang#97003 (Remove some unnecessary `rustc_allow_const_fn_unstable` attributes.) - rust-lang#97011 (Add regression test for rust-lang#28935) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
This example:
gives this error:
It took me some time to puzzle out what was happening here:
cx: &dyn DebugContext
expands to&'a dyn (DebugContext + 'a)
dyn (DebugContext + 'static)
The error message without NLL, of course, is also not very illuminating.
The text was updated successfully, but these errors were encountered: