diff options
Diffstat (limited to 'tests/ui/const-generics/generic_const_exprs/issue-79518-default_trait_method_normalization.stderr')
-rw-r--r-- | tests/ui/const-generics/generic_const_exprs/issue-79518-default_trait_method_normalization.stderr | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/ui/const-generics/generic_const_exprs/issue-79518-default_trait_method_normalization.stderr b/tests/ui/const-generics/generic_const_exprs/issue-79518-default_trait_method_normalization.stderr new file mode 100644 index 000000000..9baf9790e --- /dev/null +++ b/tests/ui/const-generics/generic_const_exprs/issue-79518-default_trait_method_normalization.stderr @@ -0,0 +1,16 @@ +error[E0308]: mismatched types + --> $DIR/issue-79518-default_trait_method_normalization.rs:16:32 + | +LL | Self::AssocInstance == [(); std::mem::size_of::<Self::Assoc>()]; + | ------------------- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected associated type, found array `[(); std::mem::size_of::<Self::Assoc>()]` + | | + | expected because this is `<Self as Foo>::Assoc` + | + = note: expected associated type `<Self as Foo>::Assoc` + found array `[(); std::mem::size_of::<Self::Assoc>()]` + = help: consider constraining the associated type `<Self as Foo>::Assoc` to `[(); std::mem::size_of::<Self::Assoc>()]` or calling a method that returns `<Self as Foo>::Assoc` + = note: for more information, visit https://doc.rust-lang.org/book/ch19-03-advanced-traits.html + +error: aborting due to previous error + +For more information about this error, try `rustc --explain E0308`. |