diff options
Diffstat (limited to 'src/test/ui/associated-types/associated-type-tuple-struct-construction.stderr')
-rw-r--r-- | src/test/ui/associated-types/associated-type-tuple-struct-construction.stderr | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/test/ui/associated-types/associated-type-tuple-struct-construction.stderr b/src/test/ui/associated-types/associated-type-tuple-struct-construction.stderr new file mode 100644 index 000000000..bca7deeb5 --- /dev/null +++ b/src/test/ui/associated-types/associated-type-tuple-struct-construction.stderr @@ -0,0 +1,19 @@ +error[E0575]: expected method or associated constant, found associated type `A::Assoc` + --> $DIR/associated-type-tuple-struct-construction.rs:7:32 + | +LL | let <Foo as A>::Assoc(n) = <Foo as A>::Assoc(2); + | ^^^^^^^^^^^^^^^^^ + | + = note: can't use a type alias as a constructor + +error[E0575]: expected method or associated constant, found associated type `A::Assoc` + --> $DIR/associated-type-tuple-struct-construction.rs:7:9 + | +LL | let <Foo as A>::Assoc(n) = <Foo as A>::Assoc(2); + | ^^^^^^^^^^^^^^^^^ + | + = note: can't use a type alias as a constructor + +error: aborting due to 2 previous errors + +For more information about this error, try `rustc --explain E0575`. |