-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
properly elaborate effects implied bounds for super traits
- Loading branch information
Showing
11 changed files
with
132 additions
and
84 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 0 additions & 22 deletions
22
tests/ui/rfcs/rfc-2632-const-trait-impl/super-traits-fail-3.yy.stderr
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,6 +17,6 @@ impl Foo for S { | |
} | ||
|
||
impl const Bar for S {} | ||
// FIXME(effects) bad span | ||
//~^ ERROR the trait bound | ||
|
||
fn main() {} |
23 changes: 18 additions & 5 deletions
23
tests/ui/rfcs/rfc-2632-const-trait-impl/super-traits-fail.stderr
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,24 @@ | ||
error[E0277]: the trait bound `Maybe: TyCompat<<(Foo::{synthetic#0},) as std::marker::effects::Intersection>::Output>` is not satisfied | ||
error[E0277]: the trait bound `Bar::{synthetic#0}: TyCompat<Foo::{synthetic#0}>` is not satisfied | ||
--> $DIR/super-traits-fail.rs:19:12 | ||
| | ||
LL | impl const Bar for S {} | ||
| ^^^ the trait `TyCompat<Foo::{synthetic#0}>` is not implemented for `Bar::{synthetic#0}`, which is required by `S: Bar` | ||
| | ||
= help: the trait `Bar` is implemented for `S` | ||
note: required for `S` to implement `Bar` | ||
--> $DIR/super-traits-fail.rs:12:7 | ||
| | ||
LL | trait Bar: ~const Foo {} | ||
| ^^^ | ||
|
||
error[E0277]: the trait bound `Maybe: TyCompat<Foo::{synthetic#0}>` is not satisfied | ||
| | ||
note: required by a bound in `Bar::{synthetic#0}` | ||
--> $DIR/super-traits-fail.rs:11:1 | ||
--> $DIR/super-traits-fail.rs:12:12 | ||
| | ||
LL | #[const_trait] | ||
| ^^^^^^^^^^^^^^ required by this bound in `Bar::{synthetic#0}` | ||
LL | trait Bar: ~const Foo {} | ||
| ^^^^^^^^^^ required by this bound in `Bar::{synthetic#0}` | ||
|
||
error: aborting due to 1 previous error | ||
error: aborting due to 2 previous errors | ||
|
||
For more information about this error, try `rustc --explain E0277`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 0 additions & 22 deletions
22
tests/ui/rfcs/rfc-2632-const-trait-impl/super-traits.stderr
This file was deleted.
Oops, something went wrong.