about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/test/ui/const-generics/defaults/mismatch.full.stderr8
-rw-r--r--src/test/ui/const-generics/defaults/mismatch.min.stderr8
-rw-r--r--src/test/ui/const-generics/defaults/mismatch.rs5
3 files changed, 13 insertions, 8 deletions
diff --git a/src/test/ui/const-generics/defaults/mismatch.full.stderr b/src/test/ui/const-generics/defaults/mismatch.full.stderr
index 741137afe45..4aa8401ab22 100644
--- a/src/test/ui/const-generics/defaults/mismatch.full.stderr
+++ b/src/test/ui/const-generics/defaults/mismatch.full.stderr
@@ -10,7 +10,7 @@ LL |     let e: Example::<13> = ();
            found unit type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/mismatch.rs:14:34
+  --> $DIR/mismatch.rs:15:34
    |
 LL |     let e: Example2::<u32, 13> = ();
    |            -------------------   ^^ expected struct `Example2`, found `()`
@@ -21,7 +21,7 @@ LL |     let e: Example2::<u32, 13> = ();
            found unit type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/mismatch.rs:16:34
+  --> $DIR/mismatch.rs:18:34
    |
 LL |     let e: Example3::<13, u32> = ();
    |            -------------------   ^^ expected struct `Example3`, found `()`
@@ -32,7 +32,7 @@ LL |     let e: Example3::<13, u32> = ();
            found unit type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/mismatch.rs:18:28
+  --> $DIR/mismatch.rs:21:28
    |
 LL |     let e: Example3::<7> = ();
    |            -------------   ^^ expected struct `Example3`, found `()`
@@ -43,7 +43,7 @@ LL |     let e: Example3::<7> = ();
            found unit type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/mismatch.rs:20:28
+  --> $DIR/mismatch.rs:24:28
    |
 LL |     let e: Example4::<7> = ();
    |            -------------   ^^ expected struct `Example4`, found `()`
diff --git a/src/test/ui/const-generics/defaults/mismatch.min.stderr b/src/test/ui/const-generics/defaults/mismatch.min.stderr
index 741137afe45..4aa8401ab22 100644
--- a/src/test/ui/const-generics/defaults/mismatch.min.stderr
+++ b/src/test/ui/const-generics/defaults/mismatch.min.stderr
@@ -10,7 +10,7 @@ LL |     let e: Example::<13> = ();
            found unit type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/mismatch.rs:14:34
+  --> $DIR/mismatch.rs:15:34
    |
 LL |     let e: Example2::<u32, 13> = ();
    |            -------------------   ^^ expected struct `Example2`, found `()`
@@ -21,7 +21,7 @@ LL |     let e: Example2::<u32, 13> = ();
            found unit type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/mismatch.rs:16:34
+  --> $DIR/mismatch.rs:18:34
    |
 LL |     let e: Example3::<13, u32> = ();
    |            -------------------   ^^ expected struct `Example3`, found `()`
@@ -32,7 +32,7 @@ LL |     let e: Example3::<13, u32> = ();
            found unit type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/mismatch.rs:18:28
+  --> $DIR/mismatch.rs:21:28
    |
 LL |     let e: Example3::<7> = ();
    |            -------------   ^^ expected struct `Example3`, found `()`
@@ -43,7 +43,7 @@ LL |     let e: Example3::<7> = ();
            found unit type `()`
 
 error[E0308]: mismatched types
-  --> $DIR/mismatch.rs:20:28
+  --> $DIR/mismatch.rs:24:28
    |
 LL |     let e: Example4::<7> = ();
    |            -------------   ^^ expected struct `Example4`, found `()`
diff --git a/src/test/ui/const-generics/defaults/mismatch.rs b/src/test/ui/const-generics/defaults/mismatch.rs
index cfc8594f17c..9d9a8793aaa 100644
--- a/src/test/ui/const-generics/defaults/mismatch.rs
+++ b/src/test/ui/const-generics/defaults/mismatch.rs
@@ -11,12 +11,17 @@ pub struct Example4<const N: usize=13, const M: usize=4>;
 fn main() {
     let e: Example::<13> = ();
     //~^ Error: mismatched types
+    //~| expected struct `Example`
     let e: Example2::<u32, 13> = ();
     //~^ Error: mismatched types
+    //~| expected struct `Example2`
     let e: Example3::<13, u32> = ();
     //~^ Error: mismatched types
+    //~| expected struct `Example3`
     let e: Example3::<7> = ();
     //~^ Error: mismatched types
+    //~| expected struct `Example3<7_usize>`
     let e: Example4::<7> = ();
     //~^ Error: mismatched types
+    //~| expected struct `Example4<7_usize>`
 }