about summary refs log tree commit diff
path: root/src/test/ui/ufcs
diff options
context:
space:
mode:
authorJonas Schievink <jonasschievink@gmail.com>2019-06-13 21:36:15 +0200
committerJonas Schievink <jonasschievink@gmail.com>2020-02-21 19:41:21 +0100
commita323ff2c864801fdc8e044e88f11efb49a565ed1 (patch)
treeb9de022262d7a61c7c233f80595a1e978dc3d658 /src/test/ui/ufcs
parent187f3d73abf35404b12782993d6e8880e866d6d1 (diff)
downloadrust-a323ff2c864801fdc8e044e88f11efb49a565ed1.tar.gz
rust-a323ff2c864801fdc8e044e88f11efb49a565ed1.zip
Implement RFC 2532 – Associated Type Defaults
Diffstat (limited to 'src/test/ui/ufcs')
-rw-r--r--src/test/ui/ufcs/ufcs-partially-resolved.rs4
-rw-r--r--src/test/ui/ufcs/ufcs-partially-resolved.stderr10
2 files changed, 7 insertions, 7 deletions
diff --git a/src/test/ui/ufcs/ufcs-partially-resolved.rs b/src/test/ui/ufcs/ufcs-partially-resolved.rs
index 66d4db3ebaf..e8c767b13e9 100644
--- a/src/test/ui/ufcs/ufcs-partially-resolved.rs
+++ b/src/test/ui/ufcs/ufcs-partially-resolved.rs
@@ -35,7 +35,7 @@ fn main() {
     <u8 as A>::N::NN; //~ ERROR cannot find associated type `N` in `A`
     let _: <u8 as Tr>::Y::NN; //~ ERROR ambiguous associated type
     let _: <u8 as E>::Y::NN; //~ ERROR expected associated type, found variant `E::Y`
-    <u8 as Tr>::Y::NN; //~ ERROR no associated item named `NN` found
+    <u8 as Tr>::Y::NN; //~ ERROR no associated item named `NN` found for type `u16`
     <u8 as E>::Y::NN; //~ ERROR expected associated type, found variant `E::Y`
 
     let _: <u8 as Tr::N>::NN; //~ ERROR cannot find associated type `NN` in `Tr::N`
@@ -52,5 +52,5 @@ fn main() {
     let _: <u8 as Dr>::Z; //~ ERROR expected associated type, found method `Dr::Z`
     <u8 as Dr>::X; //~ ERROR expected method or associated constant, found associated type `Dr::X`
     let _: <u8 as Dr>::Z::N; //~ ERROR expected associated type, found method `Dr::Z`
-    <u8 as Dr>::X::N; //~ ERROR no associated item named `N` found
+    <u8 as Dr>::X::N; //~ ERROR no associated item named `N` found for type `u16`
 }
diff --git a/src/test/ui/ufcs/ufcs-partially-resolved.stderr b/src/test/ui/ufcs/ufcs-partially-resolved.stderr
index 60ebe8ee053..e5e6ed9fac9 100644
--- a/src/test/ui/ufcs/ufcs-partially-resolved.stderr
+++ b/src/test/ui/ufcs/ufcs-partially-resolved.stderr
@@ -205,19 +205,19 @@ error[E0223]: ambiguous associated type
   --> $DIR/ufcs-partially-resolved.rs:36:12
    |
 LL |     let _: <u8 as Tr>::Y::NN;
-   |            ^^^^^^^^^^^^^^^^^ help: use fully-qualified syntax: `<<u8 as Tr>::Y as Trait>::NN`
+   |            ^^^^^^^^^^^^^^^^^ help: use fully-qualified syntax: `<u16 as Trait>::NN`
 
-error[E0599]: no associated item named `NN` found for associated type `<u8 as Tr>::Y` in the current scope
+error[E0599]: no associated item named `NN` found for type `u16` in the current scope
   --> $DIR/ufcs-partially-resolved.rs:38:20
    |
 LL |     <u8 as Tr>::Y::NN;
-   |                    ^^ associated item not found in `<u8 as Tr>::Y`
+   |                    ^^ associated item not found in `u16`
 
-error[E0599]: no associated item named `N` found for associated type `<u8 as Dr>::X` in the current scope
+error[E0599]: no associated item named `N` found for type `u16` in the current scope
   --> $DIR/ufcs-partially-resolved.rs:55:20
    |
 LL |     <u8 as Dr>::X::N;
-   |                    ^ associated item not found in `<u8 as Dr>::X`
+   |                    ^ associated item not found in `u16`
 
 error: aborting due to 32 previous errors