diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:02:58 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:02:58 +0000 |
commit | 698f8c2f01ea549d77d7dc3338a12e04c11057b9 (patch) | |
tree | 173a775858bd501c378080a10dca74132f05bc50 /src/test/ui/associated-types/associated-types-binding-to-type-defined-in-supertrait.stderr | |
parent | Initial commit. (diff) | |
download | rustc-698f8c2f01ea549d77d7dc3338a12e04c11057b9.tar.xz rustc-698f8c2f01ea549d77d7dc3338a12e04c11057b9.zip |
Adding upstream version 1.64.0+dfsg1.upstream/1.64.0+dfsg1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/associated-types/associated-types-binding-to-type-defined-in-supertrait.stderr | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/src/test/ui/associated-types/associated-types-binding-to-type-defined-in-supertrait.stderr b/src/test/ui/associated-types/associated-types-binding-to-type-defined-in-supertrait.stderr new file mode 100644 index 000000000..0cccc6b38 --- /dev/null +++ b/src/test/ui/associated-types/associated-types-binding-to-type-defined-in-supertrait.stderr @@ -0,0 +1,37 @@ +error[E0271]: type mismatch resolving `<ModelT as Vehicle>::Color == Blue` + --> $DIR/associated-types-binding-to-type-defined-in-supertrait.rs:31:10 + | +LL | fn b() { blue_car(ModelT); } + | ^^^^^^^^ type mismatch resolving `<ModelT as Vehicle>::Color == Blue` + | +note: expected this to be `Blue` + --> $DIR/associated-types-binding-to-type-defined-in-supertrait.rs:16:40 + | +LL | impl Vehicle for ModelT { type Color = Black; } + | ^^^^^ +note: required by a bound in `blue_car` + --> $DIR/associated-types-binding-to-type-defined-in-supertrait.rs:27:19 + | +LL | fn blue_car<C:Car<Color=Blue>>(c: C) { + | ^^^^^^^^^^ required by this bound in `blue_car` + +error[E0271]: type mismatch resolving `<ModelU as Vehicle>::Color == Black` + --> $DIR/associated-types-binding-to-type-defined-in-supertrait.rs:32:10 + | +LL | fn c() { black_car(ModelU); } + | ^^^^^^^^^ type mismatch resolving `<ModelU as Vehicle>::Color == Black` + | +note: expected this to be `Black` + --> $DIR/associated-types-binding-to-type-defined-in-supertrait.rs:21:40 + | +LL | impl Vehicle for ModelU { type Color = Blue; } + | ^^^^ +note: required by a bound in `black_car` + --> $DIR/associated-types-binding-to-type-defined-in-supertrait.rs:24:20 + | +LL | fn black_car<C:Car<Color=Black>>(c: C) { + | ^^^^^^^^^^^ required by this bound in `black_car` + +error: aborting due to 2 previous errors + +For more information about this error, try `rustc --explain E0271`. |