Closed dwrensha closed 4 years ago
Fixed in current stable, beta and nightly:
error[E0637]: `&` without an explicit lifetime name cannot be used here
--> file55.rs:2:36
|
2 | pub trait FooExt where for<'b> &'b &mut Self: Foo {}
| ^ explicit lifetime name needed here
error[E0277]: the trait bound `for<'b> &'b &'static mut T: Foo` is not satisfied
--> file55.rs:3:9
|
2 | pub trait FooExt where for<'b> &'b &mut Self: Foo {}
| --- required by this bound in `FooExt`
3 | impl<T> FooExt for T where for<'a> &'a mut T: Foo {}
| ^^^^^^ the trait `for<'b> Foo` is not implemented for `&'b &'static mut T`
error: aborting due to 2 previous errors
The second error should probably not be emitted as I believe it is caused by a placeholder 'static
lifetime used during recovery. We should introduce (or use if it is already there) a lifetime equivalent to TyErr
.
This only happens in builds with debug assertions. It's not fixed in master.
Assigning P-low
as discussed as part of the Prioritization Working Group process and removing I-prioritize
.
Using a
rustc
built from commit 853c4774 with debug assertions enabled (debug=true
in config.toml), I'm seeing an internal compiler error on the following input (found by fuzz-rustc):