about summary refs log tree commit diff
diff options
context:
space:
mode:
authorYuning Zhang <codeworm96@outlook.com>2018-12-31 20:43:08 -0500
committerYuning Zhang <codeworm96@outlook.com>2018-12-31 20:43:08 -0500
commit710dcbd3818deca8f193a45e321b58af3c24feae (patch)
tree0bb5f760a042393b0e4eb583f1b776f3cd196ba7
parent6efaef61899f6551914156f69809aa7d5854399d (diff)
downloadrust-710dcbd3818deca8f193a45e321b58af3c24feae.tar.gz
rust-710dcbd3818deca8f193a45e321b58af3c24feae.zip
Improve type mismatch error messages
Replace "integral variable" with "integer" and replace
"floating-point variable" with "floating-point number" to make the
message less confusing.
-rw-r--r--src/librustc/ty/error.rs4
-rw-r--r--src/test/ui/bad/bad-const-type.rs2
-rw-r--r--src/test/ui/bad/bad-const-type.stderr2
-rw-r--r--src/test/ui/binop/binop-logic-int.stderr4
-rw-r--r--src/test/ui/blind/blind-item-block-middle.stderr2
-rw-r--r--src/test/ui/chalkify/type_inference.stderr2
-rw-r--r--src/test/ui/coercion/coerce-to-bang.stderr20
-rw-r--r--src/test/ui/consts/const-integer-bool-ops.rs16
-rw-r--r--src/test/ui/consts/const-integer-bool-ops.stderr16
-rw-r--r--src/test/ui/conversion-methods.stderr2
-rw-r--r--src/test/ui/did_you_mean/issue-53280-expected-float-found-integer-literal.stderr10
-rw-r--r--src/test/ui/error-codes/E0070.stderr2
-rw-r--r--src/test/ui/float-literal-inference-restrictions.stderr2
-rw-r--r--src/test/ui/fully-qualified-type/fully-qualified-type-name1.rs2
-rw-r--r--src/test/ui/fully-qualified-type/fully-qualified-type-name1.stderr2
-rw-r--r--src/test/ui/generic/generic-arg-mismatch-recover.stderr2
-rw-r--r--src/test/ui/if/if-let-arm-types.rs2
-rw-r--r--src/test/ui/if/if-let-arm-types.stderr4
-rw-r--r--src/test/ui/integral-variable-unification-error.rs2
-rw-r--r--src/test/ui/integral-variable-unification-error.stderr2
-rw-r--r--src/test/ui/issues/issue-13407.stderr2
-rw-r--r--src/test/ui/issues/issue-14091.stderr2
-rw-r--r--src/test/ui/issues/issue-19991.rs2
-rw-r--r--src/test/ui/issues/issue-19991.stderr4
-rw-r--r--src/test/ui/issues/issue-33504.stderr2
-rw-r--r--src/test/ui/issues/issue-37665.stderr2
-rw-r--r--src/test/ui/issues/issue-4201.rs2
-rw-r--r--src/test/ui/issues/issue-4201.stderr4
-rw-r--r--src/test/ui/issues/issue-4968.rs2
-rw-r--r--src/test/ui/issues/issue-4968.stderr2
-rw-r--r--src/test/ui/keyword/keyword-false-as-identifier.stderr2
-rw-r--r--src/test/ui/keyword/keyword-true-as-identifier.stderr2
-rw-r--r--src/test/ui/loops/loop-break-value.stderr8
-rw-r--r--src/test/ui/match/match-range-fail.stderr2
-rw-r--r--src/test/ui/methods/method-self-arg-1.rs2
-rw-r--r--src/test/ui/methods/method-self-arg-1.stderr2
-rw-r--r--src/test/ui/mir-unpretty.stderr2
-rw-r--r--src/test/ui/mismatched_types/E0409.stderr2
-rw-r--r--src/test/ui/mismatched_types/abridged.stderr4
-rw-r--r--src/test/ui/mismatched_types/for-loop-has-unit-body.stderr2
-rw-r--r--src/test/ui/proc-macro/span-preservation.stderr2
-rw-r--r--src/test/ui/repeat_count.rs2
-rw-r--r--src/test/ui/repeat_count.stderr2
-rw-r--r--src/test/ui/slightly-nice-generic-literal-messages.rs2
-rw-r--r--src/test/ui/slightly-nice-generic-literal-messages.stderr2
-rw-r--r--src/test/ui/structs/struct-base-wrong-type-2.rs2
-rw-r--r--src/test/ui/structs/struct-base-wrong-type-2.stderr2
-rw-r--r--src/test/ui/structs/struct-base-wrong-type.rs2
-rw-r--r--src/test/ui/structs/struct-base-wrong-type.stderr2
-rw-r--r--src/test/ui/structs/structure-constructor-type-mismatch.rs12
-rw-r--r--src/test/ui/structs/structure-constructor-type-mismatch.stderr22
-rw-r--r--src/test/ui/try-block/try-block-type-error.stderr2
-rw-r--r--src/test/ui/type/type-mismatch-multiple.rs2
-rw-r--r--src/test/ui/type/type-mismatch-multiple.stderr2
54 files changed, 105 insertions, 105 deletions
diff --git a/src/librustc/ty/error.rs b/src/librustc/ty/error.rs
index c491fdd9957..6b931e39a05 100644
--- a/src/librustc/ty/error.rs
+++ b/src/librustc/ty/error.rs
@@ -200,8 +200,8 @@ impl<'a, 'gcx, 'lcx, 'tcx> ty::TyS<'tcx> {
             ty::GeneratorWitness(..) => "generator witness".into(),
             ty::Tuple(..) => "tuple".into(),
             ty::Infer(ty::TyVar(_)) => "inferred type".into(),
-            ty::Infer(ty::IntVar(_)) => "integral variable".into(),
-            ty::Infer(ty::FloatVar(_)) => "floating-point variable".into(),
+            ty::Infer(ty::IntVar(_)) => "integer".into(),
+            ty::Infer(ty::FloatVar(_)) => "floating-point number".into(),
             ty::Placeholder(..) => "placeholder type".into(),
             ty::Bound(..) => "bound type".into(),
             ty::Infer(ty::FreshTy(_)) => "fresh type".into(),
diff --git a/src/test/ui/bad/bad-const-type.rs b/src/test/ui/bad/bad-const-type.rs
index b46f5933010..8121929e096 100644
--- a/src/test/ui/bad/bad-const-type.rs
+++ b/src/test/ui/bad/bad-const-type.rs
@@ -2,5 +2,5 @@ static i: String = 10;
 //~^ ERROR mismatched types
 //~| expected type `std::string::String`
 //~| found type `{integer}`
-//~| expected struct `std::string::String`, found integral variable
+//~| expected struct `std::string::String`, found integer
 fn main() { println!("{}", i); }
diff --git a/src/test/ui/bad/bad-const-type.stderr b/src/test/ui/bad/bad-const-type.stderr
index 694e692a5be..677dc72652e 100644
--- a/src/test/ui/bad/bad-const-type.stderr
+++ b/src/test/ui/bad/bad-const-type.stderr
@@ -4,7 +4,7 @@ error[E0308]: mismatched types
 LL | static i: String = 10;
    |                    ^^
    |                    |
-   |                    expected struct `std::string::String`, found integral variable
+   |                    expected struct `std::string::String`, found integer
    |                    help: try using a conversion method: `10.to_string()`
    |
    = note: expected type `std::string::String`
diff --git a/src/test/ui/binop/binop-logic-int.stderr b/src/test/ui/binop/binop-logic-int.stderr
index 9ca9e64211c..b699b390b8b 100644
--- a/src/test/ui/binop/binop-logic-int.stderr
+++ b/src/test/ui/binop/binop-logic-int.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/binop-logic-int.rs:1:21
    |
 LL | fn main() { let x = 1 && 2; }
-   |                     ^ expected bool, found integral variable
+   |                     ^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
@@ -11,7 +11,7 @@ error[E0308]: mismatched types
   --> $DIR/binop-logic-int.rs:1:26
    |
 LL | fn main() { let x = 1 && 2; }
-   |                          ^ expected bool, found integral variable
+   |                          ^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
diff --git a/src/test/ui/blind/blind-item-block-middle.stderr b/src/test/ui/blind/blind-item-block-middle.stderr
index 05a62340449..389b63c0adf 100644
--- a/src/test/ui/blind/blind-item-block-middle.stderr
+++ b/src/test/ui/blind/blind-item-block-middle.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/blind-item-block-middle.rs:6:9
    |
 LL |     let bar = 5;
-   |         ^^^ expected integral variable, found struct `foo::bar`
+   |         ^^^ expected integer, found struct `foo::bar`
    |
    = note: expected type `{integer}`
               found type `foo::bar`
diff --git a/src/test/ui/chalkify/type_inference.stderr b/src/test/ui/chalkify/type_inference.stderr
index 49ed97d7168..d65b701307b 100644
--- a/src/test/ui/chalkify/type_inference.stderr
+++ b/src/test/ui/chalkify/type_inference.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/type_inference.rs:21:14
    |
 LL |     only_foo(x); //~ ERROR mismatched types
-   |              ^ expected i32, found floating-point variable
+   |              ^ expected i32, found floating-point number
    |
    = note: expected type `i32`
               found type `{float}`
diff --git a/src/test/ui/coercion/coerce-to-bang.stderr b/src/test/ui/coercion/coerce-to-bang.stderr
index 0795765ef2d..72e7211de7a 100644
--- a/src/test/ui/coercion/coerce-to-bang.stderr
+++ b/src/test/ui/coercion/coerce-to-bang.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:6:17
    |
 LL |     foo(return, 22, 44);
-   |                 ^^ expected !, found integral variable
+   |                 ^^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
@@ -11,7 +11,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:18:13
    |
 LL |     foo(22, 44, return); //~ ERROR mismatched types
-   |             ^^ expected !, found integral variable
+   |             ^^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
@@ -20,7 +20,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:26:12
    |
 LL |     foo(a, b, c); // ... and hence a reference to `a` is expected to diverge.
-   |            ^ expected !, found integral variable
+   |            ^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
@@ -29,7 +29,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:36:12
    |
 LL |     foo(a, b, c); //~ ERROR mismatched types
-   |            ^ expected !, found integral variable
+   |            ^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
@@ -38,7 +38,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:45:12
    |
 LL |     foo(a, b, c); //~ ERROR mismatched types
-   |            ^ expected !, found integral variable
+   |            ^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
@@ -47,7 +47,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:50:21
    |
 LL |     let x: [!; 2] = [return, 22]; //~ ERROR mismatched types
-   |                     ^^^^^^^^^^^^ expected !, found integral variable
+   |                     ^^^^^^^^^^^^ expected !, found integer
    |
    = note: expected type `[!; 2]`
               found type `[{integer}; 2]`
@@ -56,7 +56,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:55:22
    |
 LL |     let x: [!; 2] = [22, return]; //~ ERROR mismatched types
-   |                      ^^ expected !, found integral variable
+   |                      ^^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
@@ -65,7 +65,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:60:37
    |
 LL |     let x: (usize, !, usize) = (22, 44, 66); //~ ERROR mismatched types
-   |                                     ^^ expected !, found integral variable
+   |                                     ^^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
@@ -74,7 +74,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:65:41
    |
 LL |     let x: (usize, !, usize) = (return, 44, 66);
-   |                                         ^^ expected !, found integral variable
+   |                                         ^^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
@@ -83,7 +83,7 @@ error[E0308]: mismatched types
   --> $DIR/coerce-to-bang.rs:76:37
    |
 LL |     let x: (usize, !, usize) = (22, 44, return); //~ ERROR mismatched types
-   |                                     ^^ expected !, found integral variable
+   |                                     ^^ expected !, found integer
    |
    = note: expected type `!`
               found type `{integer}`
diff --git a/src/test/ui/consts/const-integer-bool-ops.rs b/src/test/ui/consts/const-integer-bool-ops.rs
index d557d70a52f..f0d5a558e35 100644
--- a/src/test/ui/consts/const-integer-bool-ops.rs
+++ b/src/test/ui/consts/const-integer-bool-ops.rs
@@ -1,8 +1,8 @@
 const X: usize = 42 && 39;
 //~^ ERROR mismatched types
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
 //~| expected usize, found bool
 const ARR: [i32; X] = [99; 34];
@@ -10,9 +10,9 @@ const ARR: [i32; X] = [99; 34];
 
 const X1: usize = 42 || 39;
 //~^ ERROR mismatched types
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
 //~| expected usize, found bool
 const ARR1: [i32; X1] = [99; 47];
@@ -20,9 +20,9 @@ const ARR1: [i32; X1] = [99; 47];
 
 const X2: usize = -42 || -39;
 //~^ ERROR mismatched types
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
 //~| expected usize, found bool
 const ARR2: [i32; X2] = [99; 18446744073709551607];
@@ -30,9 +30,9 @@ const ARR2: [i32; X2] = [99; 18446744073709551607];
 
 const X3: usize = -42 && -39;
 //~^ ERROR mismatched types
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
 //~| expected usize, found bool
 const ARR3: [i32; X3] = [99; 6];
diff --git a/src/test/ui/consts/const-integer-bool-ops.stderr b/src/test/ui/consts/const-integer-bool-ops.stderr
index 8ac3f617a36..7885eb446f0 100644
--- a/src/test/ui/consts/const-integer-bool-ops.stderr
+++ b/src/test/ui/consts/const-integer-bool-ops.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/const-integer-bool-ops.rs:1:18
    |
 LL | const X: usize = 42 && 39;
-   |                  ^^ expected bool, found integral variable
+   |                  ^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
@@ -11,7 +11,7 @@ error[E0308]: mismatched types
   --> $DIR/const-integer-bool-ops.rs:1:24
    |
 LL | const X: usize = 42 && 39;
-   |                        ^^ expected bool, found integral variable
+   |                        ^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
@@ -32,7 +32,7 @@ error[E0308]: mismatched types
   --> $DIR/const-integer-bool-ops.rs:11:19
    |
 LL | const X1: usize = 42 || 39;
-   |                   ^^ expected bool, found integral variable
+   |                   ^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
@@ -41,7 +41,7 @@ error[E0308]: mismatched types
   --> $DIR/const-integer-bool-ops.rs:11:25
    |
 LL | const X1: usize = 42 || 39;
-   |                         ^^ expected bool, found integral variable
+   |                         ^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
@@ -62,7 +62,7 @@ error[E0308]: mismatched types
   --> $DIR/const-integer-bool-ops.rs:21:19
    |
 LL | const X2: usize = -42 || -39;
-   |                   ^^^ expected bool, found integral variable
+   |                   ^^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
@@ -71,7 +71,7 @@ error[E0308]: mismatched types
   --> $DIR/const-integer-bool-ops.rs:21:26
    |
 LL | const X2: usize = -42 || -39;
-   |                          ^^^ expected bool, found integral variable
+   |                          ^^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
@@ -92,7 +92,7 @@ error[E0308]: mismatched types
   --> $DIR/const-integer-bool-ops.rs:31:19
    |
 LL | const X3: usize = -42 && -39;
-   |                   ^^^ expected bool, found integral variable
+   |                   ^^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
@@ -101,7 +101,7 @@ error[E0308]: mismatched types
   --> $DIR/const-integer-bool-ops.rs:31:26
    |
 LL | const X3: usize = -42 && -39;
-   |                          ^^^ expected bool, found integral variable
+   |                          ^^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
diff --git a/src/test/ui/conversion-methods.stderr b/src/test/ui/conversion-methods.stderr
index 78099ea9e7c..33fff4a0f68 100644
--- a/src/test/ui/conversion-methods.stderr
+++ b/src/test/ui/conversion-methods.stderr
@@ -28,7 +28,7 @@ error[E0308]: mismatched types
 LL |     let _but_should_the_play: String = 2; // Perhaps surprisingly, we suggest .to_string() here
    |                                        ^
    |                                        |
-   |                                        expected struct `std::string::String`, found integral variable
+   |                                        expected struct `std::string::String`, found integer
    |                                        help: try using a conversion method: `2.to_string()`
    |
    = note: expected type `std::string::String`
diff --git a/src/test/ui/did_you_mean/issue-53280-expected-float-found-integer-literal.stderr b/src/test/ui/did_you_mean/issue-53280-expected-float-found-integer-literal.stderr
index 9f09c9b53cc..301704ec0c7 100644
--- a/src/test/ui/did_you_mean/issue-53280-expected-float-found-integer-literal.stderr
+++ b/src/test/ui/did_you_mean/issue-53280-expected-float-found-integer-literal.stderr
@@ -4,7 +4,7 @@ error[E0308]: mismatched types
 LL |     let sixteen: f32 = 16;
    |                        ^^
    |                        |
-   |                        expected f32, found integral variable
+   |                        expected f32, found integer
    |                        help: use a float literal: `16.0`
    |
    = note: expected type `f32`
@@ -16,7 +16,7 @@ error[E0308]: mismatched types
 LL |     let a_million_and_seventy: f64 = 1_000_070;
    |                                      ^^^^^^^^^
    |                                      |
-   |                                      expected f64, found integral variable
+   |                                      expected f64, found integer
    |                                      help: use a float literal: `1_000_070.0`
    |
    = note: expected type `f64`
@@ -28,7 +28,7 @@ error[E0308]: mismatched types
 LL |     let negative_nine: f32 = -9;
    |                              ^^
    |                              |
-   |                              expected f32, found integral variable
+   |                              expected f32, found integer
    |                              help: use a float literal: `-9.0`
    |
    = note: expected type `f32`
@@ -38,7 +38,7 @@ error[E0308]: mismatched types
   --> $DIR/issue-53280-expected-float-found-integer-literal.rs:15:30
    |
 LL |     let sixteen_again: f64 = 0x10;
-   |                              ^^^^ expected f64, found integral variable
+   |                              ^^^^ expected f64, found integer
    |
    = note: expected type `f64`
               found type `{integer}`
@@ -47,7 +47,7 @@ error[E0308]: mismatched types
   --> $DIR/issue-53280-expected-float-found-integer-literal.rs:17:30
    |
 LL |     let and_once_more: f32 = 0o20;
-   |                              ^^^^ expected f32, found integral variable
+   |                              ^^^^ expected f32, found integer
    |
    = note: expected type `f32`
               found type `{integer}`
diff --git a/src/test/ui/error-codes/E0070.stderr b/src/test/ui/error-codes/E0070.stderr
index a6a8925d991..4c1cfd858e6 100644
--- a/src/test/ui/error-codes/E0070.stderr
+++ b/src/test/ui/error-codes/E0070.stderr
@@ -14,7 +14,7 @@ error[E0308]: mismatched types
   --> $DIR/E0070.rs:8:25
    |
 LL |     some_other_func() = 4; //~ ERROR E0070
-   |                         ^ expected (), found integral variable
+   |                         ^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/float-literal-inference-restrictions.stderr b/src/test/ui/float-literal-inference-restrictions.stderr
index ea12c9caa77..a69c13507e6 100644
--- a/src/test/ui/float-literal-inference-restrictions.stderr
+++ b/src/test/ui/float-literal-inference-restrictions.stderr
@@ -4,7 +4,7 @@ error[E0308]: mismatched types
 LL |     let x: f32 = 1; //~ ERROR mismatched types
    |                  ^
    |                  |
-   |                  expected f32, found integral variable
+   |                  expected f32, found integer
    |                  help: use a float literal: `1.0`
    |
    = note: expected type `f32`
diff --git a/src/test/ui/fully-qualified-type/fully-qualified-type-name1.rs b/src/test/ui/fully-qualified-type/fully-qualified-type-name1.rs
index 8fdcbbae8de..7e5b884103e 100644
--- a/src/test/ui/fully-qualified-type/fully-qualified-type-name1.rs
+++ b/src/test/ui/fully-qualified-type/fully-qualified-type-name1.rs
@@ -6,5 +6,5 @@ fn main() {
     //~^ ERROR mismatched types
     //~| expected type `std::option::Option<usize>`
     //~| found type `{integer}`
-    //~| expected enum `std::option::Option`, found integral variable
+    //~| expected enum `std::option::Option`, found integer
 }
diff --git a/src/test/ui/fully-qualified-type/fully-qualified-type-name1.stderr b/src/test/ui/fully-qualified-type/fully-qualified-type-name1.stderr
index d16cbcfe1d5..62ded3e255a 100644
--- a/src/test/ui/fully-qualified-type/fully-qualified-type-name1.stderr
+++ b/src/test/ui/fully-qualified-type/fully-qualified-type-name1.stderr
@@ -4,7 +4,7 @@ error[E0308]: mismatched types
 LL |     x = 5;
    |         ^
    |         |
-   |         expected enum `std::option::Option`, found integral variable
+   |         expected enum `std::option::Option`, found integer
    |         help: try using a variant of the expected type: `Some(5)`
    |
    = note: expected type `std::option::Option<usize>`
diff --git a/src/test/ui/generic/generic-arg-mismatch-recover.stderr b/src/test/ui/generic/generic-arg-mismatch-recover.stderr
index 1576b3c3915..37f6c61f06d 100644
--- a/src/test/ui/generic/generic-arg-mismatch-recover.stderr
+++ b/src/test/ui/generic/generic-arg-mismatch-recover.stderr
@@ -8,7 +8,7 @@ error[E0308]: mismatched types
   --> $DIR/generic-arg-mismatch-recover.rs:6:33
    |
 LL |     Foo::<'static, 'static, ()>(&0); //~ ERROR wrong number of lifetime arguments
-   |                                 ^^ expected (), found integral variable
+   |                                 ^^ expected (), found integer
    |
    = note: expected type `&'static ()`
               found type `&{integer}`
diff --git a/src/test/ui/if/if-let-arm-types.rs b/src/test/ui/if/if-let-arm-types.rs
index ca115cc219e..749c089ae97 100644
--- a/src/test/ui/if/if-let-arm-types.rs
+++ b/src/test/ui/if/if-let-arm-types.rs
@@ -1,6 +1,6 @@
 fn main() {
     if let Some(b) = None { //~ ERROR: `if let` arms have incompatible types
-        //~^ expected (), found integral variable
+        //~^ expected (), found integer
         //~| expected type `()`
         //~| found type `{integer}`
         ()
diff --git a/src/test/ui/if/if-let-arm-types.stderr b/src/test/ui/if/if-let-arm-types.stderr
index 23cf5a45af0..fcf9e4695f6 100644
--- a/src/test/ui/if/if-let-arm-types.stderr
+++ b/src/test/ui/if/if-let-arm-types.stderr
@@ -2,13 +2,13 @@ error[E0308]: `if let` arms have incompatible types
   --> $DIR/if-let-arm-types.rs:2:5
    |
 LL | /     if let Some(b) = None { //~ ERROR: `if let` arms have incompatible types
-LL | |         //~^ expected (), found integral variable
+LL | |         //~^ expected (), found integer
 LL | |         //~| expected type `()`
 LL | |         //~| found type `{integer}`
 ...  |
 LL | |         1
 LL | |     };
-   | |_____^ expected (), found integral variable
+   | |_____^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/integral-variable-unification-error.rs b/src/test/ui/integral-variable-unification-error.rs
index 98a77e9c82f..3eefcdea3d9 100644
--- a/src/test/ui/integral-variable-unification-error.rs
+++ b/src/test/ui/integral-variable-unification-error.rs
@@ -4,5 +4,5 @@ fn main() {
     //~^ ERROR mismatched types
     //~| expected type `{integer}`
     //~| found type `{float}`
-    //~| expected integral variable, found floating-point variable
+    //~| expected integer, found floating-point number
 }
diff --git a/src/test/ui/integral-variable-unification-error.stderr b/src/test/ui/integral-variable-unification-error.stderr
index 7670f7a0e8d..262203b7b8e 100644
--- a/src/test/ui/integral-variable-unification-error.stderr
+++ b/src/test/ui/integral-variable-unification-error.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/integral-variable-unification-error.rs:3:9
    |
 LL |     x = 5.0;
-   |         ^^^ expected integral variable, found floating-point variable
+   |         ^^^ expected integer, found floating-point number
    |
    = note: expected type `{integer}`
               found type `{float}`
diff --git a/src/test/ui/issues/issue-13407.stderr b/src/test/ui/issues/issue-13407.stderr
index 90b5d22a284..1f4c7dfb0da 100644
--- a/src/test/ui/issues/issue-13407.stderr
+++ b/src/test/ui/issues/issue-13407.stderr
@@ -8,7 +8,7 @@ error[E0308]: mismatched types
   --> $DIR/issue-13407.rs:6:12
    |
 LL |     A::C = 1;
-   |            ^ expected struct `A::C`, found integral variable
+   |            ^ expected struct `A::C`, found integer
    |
    = note: expected type `A::C`
               found type `{integer}`
diff --git a/src/test/ui/issues/issue-14091.stderr b/src/test/ui/issues/issue-14091.stderr
index c7616e5ab4f..24a076624ed 100644
--- a/src/test/ui/issues/issue-14091.stderr
+++ b/src/test/ui/issues/issue-14091.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/issue-14091.rs:2:5
    |
 LL |     assert!(1,1);
-   |     ^^^^^^^^^^^^^ expected bool, found integral variable
+   |     ^^^^^^^^^^^^^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`
diff --git a/src/test/ui/issues/issue-19991.rs b/src/test/ui/issues/issue-19991.rs
index 349a1d77c2b..e9094ecc015 100644
--- a/src/test/ui/issues/issue-19991.rs
+++ b/src/test/ui/issues/issue-19991.rs
@@ -5,7 +5,7 @@ fn main() {
     if let Some(homura) = Some("madoka") { //~  ERROR missing an else clause
                                            //~| expected type `()`
                                            //~| found type `{integer}`
-                                           //~| expected (), found integral variable
+                                           //~| expected (), found integer
         765
     };
 }
diff --git a/src/test/ui/issues/issue-19991.stderr b/src/test/ui/issues/issue-19991.stderr
index cf3d55e8210..ee5d363c4bd 100644
--- a/src/test/ui/issues/issue-19991.stderr
+++ b/src/test/ui/issues/issue-19991.stderr
@@ -4,10 +4,10 @@ error[E0317]: if may be missing an else clause
 LL | /     if let Some(homura) = Some("madoka") { //~  ERROR missing an else clause
 LL | |                                            //~| expected type `()`
 LL | |                                            //~| found type `{integer}`
-LL | |                                            //~| expected (), found integral variable
+LL | |                                            //~| expected (), found integer
 LL | |         765
 LL | |     };
-   | |_____^ expected (), found integral variable
+   | |_____^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/issues/issue-33504.stderr b/src/test/ui/issues/issue-33504.stderr
index 95d6c55c1ea..716aa8a8632 100644
--- a/src/test/ui/issues/issue-33504.stderr
+++ b/src/test/ui/issues/issue-33504.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/issue-33504.rs:7:13
    |
 LL |         let Test = 1; //~ ERROR mismatched types
-   |             ^^^^ expected integral variable, found struct `Test`
+   |             ^^^^ expected integer, found struct `Test`
    |
    = note: expected type `{integer}`
               found type `Test`
diff --git a/src/test/ui/issues/issue-37665.stderr b/src/test/ui/issues/issue-37665.stderr
index 0022ab73e1a..c3599fab685 100644
--- a/src/test/ui/issues/issue-37665.stderr
+++ b/src/test/ui/issues/issue-37665.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/issue-37665.rs:10:17
    |
 LL |     let x: () = 0; //~ ERROR: mismatched types
-   |                 ^ expected (), found integral variable
+   |                 ^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/issues/issue-4201.rs b/src/test/ui/issues/issue-4201.rs
index c9098c843f9..2f1d6d2177e 100644
--- a/src/test/ui/issues/issue-4201.rs
+++ b/src/test/ui/issues/issue-4201.rs
@@ -5,7 +5,7 @@ fn main() {
 //~^ ERROR if may be missing an else clause
 //~| expected type `()`
 //~| found type `{integer}`
-//~| expected (), found integral variable
+//~| expected (), found integer
         1
     };
 }
diff --git a/src/test/ui/issues/issue-4201.stderr b/src/test/ui/issues/issue-4201.stderr
index ebeb870183e..4f8ec96d531 100644
--- a/src/test/ui/issues/issue-4201.stderr
+++ b/src/test/ui/issues/issue-4201.stderr
@@ -6,10 +6,10 @@ LL |       } else if false {
 LL | | //~^ ERROR if may be missing an else clause
 LL | | //~| expected type `()`
 LL | | //~| found type `{integer}`
-LL | | //~| expected (), found integral variable
+LL | | //~| expected (), found integer
 LL | |         1
 LL | |     };
-   | |_____^ expected (), found integral variable
+   | |_____^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/issues/issue-4968.rs b/src/test/ui/issues/issue-4968.rs
index 3bf65c5ce8e..383b9ecd466 100644
--- a/src/test/ui/issues/issue-4968.rs
+++ b/src/test/ui/issues/issue-4968.rs
@@ -6,5 +6,5 @@ fn main() {
     //~^ ERROR mismatched types
     //~| expected type `{integer}`
     //~| found type `(isize, isize)`
-    //~| expected integral variable, found tuple
+    //~| expected integer, found tuple
 }
diff --git a/src/test/ui/issues/issue-4968.stderr b/src/test/ui/issues/issue-4968.stderr
index 2f6b4b95882..a925783723b 100644
--- a/src/test/ui/issues/issue-4968.stderr
+++ b/src/test/ui/issues/issue-4968.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/issue-4968.rs:5:16
    |
 LL |     match 42 { A => () }
-   |                ^ expected integral variable, found tuple
+   |                ^ expected integer, found tuple
    |
    = note: expected type `{integer}`
               found type `(isize, isize)`
diff --git a/src/test/ui/keyword/keyword-false-as-identifier.stderr b/src/test/ui/keyword/keyword-false-as-identifier.stderr
index de5dfcfbe43..6c8dffa7e22 100644
--- a/src/test/ui/keyword/keyword-false-as-identifier.stderr
+++ b/src/test/ui/keyword/keyword-false-as-identifier.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/keyword-false-as-identifier.rs:2:9
    |
 LL |     let false = 22; //~ error: mismatched types
-   |         ^^^^^ expected integral variable, found bool
+   |         ^^^^^ expected integer, found bool
    |
    = note: expected type `{integer}`
               found type `bool`
diff --git a/src/test/ui/keyword/keyword-true-as-identifier.stderr b/src/test/ui/keyword/keyword-true-as-identifier.stderr
index cc5c6fe4556..e5d3938e54a 100644
--- a/src/test/ui/keyword/keyword-true-as-identifier.stderr
+++ b/src/test/ui/keyword/keyword-true-as-identifier.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/keyword-true-as-identifier.rs:2:9
    |
 LL |     let true = 22; //~ error: mismatched types
-   |         ^^^^ expected integral variable, found bool
+   |         ^^^^ expected integer, found bool
    |
    = note: expected type `{integer}`
               found type `bool`
diff --git a/src/test/ui/loops/loop-break-value.stderr b/src/test/ui/loops/loop-break-value.stderr
index 8fc4ec94366..3e009c007e0 100644
--- a/src/test/ui/loops/loop-break-value.stderr
+++ b/src/test/ui/loops/loop-break-value.stderr
@@ -91,7 +91,7 @@ error[E0308]: mismatched types
   --> $DIR/loop-break-value.rs:11:19
    |
 LL |             break 123; //~ ERROR mismatched types
-   |                   ^^^ expected &str, found integral variable
+   |                   ^^^ expected &str, found integer
    |
    = note: expected type `&str`
               found type `{integer}`
@@ -118,7 +118,7 @@ error[E0308]: mismatched types
   --> $DIR/loop-break-value.rs:73:26
    |
 LL |                 break 'c 123; //~ ERROR mismatched types
-   |                          ^^^ expected (), found integral variable
+   |                          ^^^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
@@ -136,7 +136,7 @@ error[E0308]: mismatched types
   --> $DIR/loop-break-value.rs:85:15
    |
 LL |         break 2; //~ ERROR mismatched types
-   |               ^ expected (), found integral variable
+   |               ^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
@@ -145,7 +145,7 @@ error[E0308]: mismatched types
   --> $DIR/loop-break-value.rs:90:9
    |
 LL |         break; //~ ERROR mismatched types
-   |         ^^^^^ expected (), found integral variable
+   |         ^^^^^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/match/match-range-fail.stderr b/src/test/ui/match/match-range-fail.stderr
index 8d067c703b7..54969927433 100644
--- a/src/test/ui/match/match-range-fail.stderr
+++ b/src/test/ui/match/match-range-fail.stderr
@@ -20,7 +20,7 @@ error[E0308]: mismatched types
   --> $DIR/match-range-fail.rs:17:9
    |
 LL |         'c' ..= 100 => { }
-   |         ^^^^^^^^^^^ expected integral variable, found char
+   |         ^^^^^^^^^^^ expected integer, found char
    |
    = note: expected type `{integer}`
               found type `char`
diff --git a/src/test/ui/methods/method-self-arg-1.rs b/src/test/ui/methods/method-self-arg-1.rs
index 48be31d94f2..4a78ad780c4 100644
--- a/src/test/ui/methods/method-self-arg-1.rs
+++ b/src/test/ui/methods/method-self-arg-1.rs
@@ -15,5 +15,5 @@ fn main() {
     Foo::bar(&42); //~  ERROR mismatched types
                       //~| expected type `&Foo`
                       //~| found type `&{integer}`
-                      //~| expected struct `Foo`, found integral variable
+                      //~| expected struct `Foo`, found integer
 }
diff --git a/src/test/ui/methods/method-self-arg-1.stderr b/src/test/ui/methods/method-self-arg-1.stderr
index 0756e9b68f2..8c80d01b18c 100644
--- a/src/test/ui/methods/method-self-arg-1.stderr
+++ b/src/test/ui/methods/method-self-arg-1.stderr
@@ -14,7 +14,7 @@ error[E0308]: mismatched types
   --> $DIR/method-self-arg-1.rs:15:14
    |
 LL |     Foo::bar(&42); //~  ERROR mismatched types
-   |              ^^^ expected struct `Foo`, found integral variable
+   |              ^^^ expected struct `Foo`, found integer
    |
    = note: expected type `&Foo`
               found type `&{integer}`
diff --git a/src/test/ui/mir-unpretty.stderr b/src/test/ui/mir-unpretty.stderr
index 913999c2290..59e8c0bf090 100644
--- a/src/test/ui/mir-unpretty.stderr
+++ b/src/test/ui/mir-unpretty.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/mir-unpretty.rs:4:17
    |
 LL |     let x: () = 0; //~ ERROR: mismatched types
-   |                 ^ expected (), found integral variable
+   |                 ^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/mismatched_types/E0409.stderr b/src/test/ui/mismatched_types/E0409.stderr
index 4d5bfceb74e..08f132efd05 100644
--- a/src/test/ui/mismatched_types/E0409.stderr
+++ b/src/test/ui/mismatched_types/E0409.stderr
@@ -10,7 +10,7 @@ error[E0308]: mismatched types
   --> $DIR/E0409.rs:5:23
    |
 LL |         (0, ref y) | (y, 0) => {} //~ ERROR E0409
-   |                       ^ expected &{integer}, found integral variable
+   |                       ^ expected &{integer}, found integer
    |
    = note: expected type `&{integer}`
               found type `{integer}`
diff --git a/src/test/ui/mismatched_types/abridged.stderr b/src/test/ui/mismatched_types/abridged.stderr
index 5256148c771..6a5cf7db4ee 100644
--- a/src/test/ui/mismatched_types/abridged.stderr
+++ b/src/test/ui/mismatched_types/abridged.stderr
@@ -49,7 +49,7 @@ LL | fn d() -> X<X<String, String>, String> {
    |           ---------------------------- expected `X<X<std::string::String, std::string::String>, std::string::String>` because of return type
 ...
 LL |     x //~ ERROR mismatched types
-   |     ^ expected struct `std::string::String`, found integral variable
+   |     ^ expected struct `std::string::String`, found integer
    |
    = note: expected type `X<X<_, std::string::String>, std::string::String>`
               found type `X<X<_, {integer}>, {integer}>`
@@ -61,7 +61,7 @@ LL | fn e() -> X<X<String, String>, String> {
    |           ---------------------------- expected `X<X<std::string::String, std::string::String>, std::string::String>` because of return type
 ...
 LL |     x //~ ERROR mismatched types
-   |     ^ expected struct `std::string::String`, found integral variable
+   |     ^ expected struct `std::string::String`, found integer
    |
    = note: expected type `X<X<_, std::string::String>, _>`
               found type `X<X<_, {integer}>, _>`
diff --git a/src/test/ui/mismatched_types/for-loop-has-unit-body.stderr b/src/test/ui/mismatched_types/for-loop-has-unit-body.stderr
index 1de8e18c587..25203d6f35d 100644
--- a/src/test/ui/mismatched_types/for-loop-has-unit-body.stderr
+++ b/src/test/ui/mismatched_types/for-loop-has-unit-body.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/for-loop-has-unit-body.rs:3:9
    |
 LL |         x //~ ERROR mismatched types
-   |         ^ expected (), found integral variable
+   |         ^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/proc-macro/span-preservation.stderr b/src/test/ui/proc-macro/span-preservation.stderr
index 64d0173cb9c..1f9103a6d2e 100644
--- a/src/test/ui/proc-macro/span-preservation.stderr
+++ b/src/test/ui/proc-macro/span-preservation.stderr
@@ -38,7 +38,7 @@ error[E0308]: mismatched types
 LL | extern "C" fn baz() {
    |                     - possibly return type missing here?
 LL |     0 //~ ERROR mismatched types
-   |     ^ expected (), found integral variable
+   |     ^ expected (), found integer
    |
    = note: expected type `()`
               found type `{integer}`
diff --git a/src/test/ui/repeat_count.rs b/src/test/ui/repeat_count.rs
index 74385c79497..c42dc8c9971 100644
--- a/src/test/ui/repeat_count.rs
+++ b/src/test/ui/repeat_count.rs
@@ -16,7 +16,7 @@ fn main() {
     //~^ ERROR mismatched types
     //~| expected type `usize`
     //~| found type `{float}`
-    //~| expected usize, found floating-point variable
+    //~| expected usize, found floating-point number
     let e = [0; "foo"];
     //~^ ERROR mismatched types
     //~| expected type `usize`
diff --git a/src/test/ui/repeat_count.stderr b/src/test/ui/repeat_count.stderr
index b481cd187c5..df3227bfcde 100644
--- a/src/test/ui/repeat_count.stderr
+++ b/src/test/ui/repeat_count.stderr
@@ -23,7 +23,7 @@ error[E0308]: mismatched types
   --> $DIR/repeat_count.rs:15:17
    |
 LL |     let d = [0; 0.5];
-   |                 ^^^ expected usize, found floating-point variable
+   |                 ^^^ expected usize, found floating-point number
    |
    = note: expected type `usize`
               found type `{float}`
diff --git a/src/test/ui/slightly-nice-generic-literal-messages.rs b/src/test/ui/slightly-nice-generic-literal-messages.rs
index fcbc2a169a5..cd0ee174af5 100644
--- a/src/test/ui/slightly-nice-generic-literal-messages.rs
+++ b/src/test/ui/slightly-nice-generic-literal-messages.rs
@@ -8,7 +8,7 @@ fn main() {
     //~^ ERROR mismatched types
     //~| expected type `Foo<{float}, _>`
     //~| found type `{integer}`
-    //~| expected struct `Foo`, found integral variable
+    //~| expected struct `Foo`, found integer
     }
 
 }
diff --git a/src/test/ui/slightly-nice-generic-literal-messages.stderr b/src/test/ui/slightly-nice-generic-literal-messages.stderr
index 767faf52914..76ebc007df3 100644
--- a/src/test/ui/slightly-nice-generic-literal-messages.stderr
+++ b/src/test/ui/slightly-nice-generic-literal-messages.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/slightly-nice-generic-literal-messages.rs:7:9
    |
 LL |         1 => {}
-   |         ^ expected struct `Foo`, found integral variable
+   |         ^ expected struct `Foo`, found integer
    |
    = note: expected type `Foo<{float}, _>`
               found type `{integer}`
diff --git a/src/test/ui/structs/struct-base-wrong-type-2.rs b/src/test/ui/structs/struct-base-wrong-type-2.rs
index a88c5d1c13b..562f75b8e85 100644
--- a/src/test/ui/structs/struct-base-wrong-type-2.rs
+++ b/src/test/ui/structs/struct-base-wrong-type-2.rs
@@ -15,5 +15,5 @@ fn main() {
     let f__isize = Foo { a: 2, ..4 }; //~  ERROR mismatched types
                                  //~| expected type `Foo`
                                  //~| found type `{integer}`
-                                 //~| expected struct `Foo`, found integral variable
+                                 //~| expected struct `Foo`, found integer
 }
diff --git a/src/test/ui/structs/struct-base-wrong-type-2.stderr b/src/test/ui/structs/struct-base-wrong-type-2.stderr
index 44ac3483ad6..b15ea51bb2d 100644
--- a/src/test/ui/structs/struct-base-wrong-type-2.stderr
+++ b/src/test/ui/structs/struct-base-wrong-type-2.stderr
@@ -11,7 +11,7 @@ error[E0308]: mismatched types
   --> $DIR/struct-base-wrong-type-2.rs:15:34
    |
 LL |     let f__isize = Foo { a: 2, ..4 }; //~  ERROR mismatched types
-   |                                  ^ expected struct `Foo`, found integral variable
+   |                                  ^ expected struct `Foo`, found integer
    |
    = note: expected type `Foo`
               found type `{integer}`
diff --git a/src/test/ui/structs/struct-base-wrong-type.rs b/src/test/ui/structs/struct-base-wrong-type.rs
index 83b54448151..6252673c296 100644
--- a/src/test/ui/structs/struct-base-wrong-type.rs
+++ b/src/test/ui/structs/struct-base-wrong-type.rs
@@ -14,7 +14,7 @@ static foo: Foo = Foo { a: 2, ..bar }; //~  ERROR mismatched types
 static foo_i: Foo = Foo { a: 2, ..4 }; //~  ERROR mismatched types
                                        //~| expected type `Foo`
                                        //~| found type `{integer}`
-                                       //~| expected struct `Foo`, found integral variable
+                                       //~| expected struct `Foo`, found integer
 
 fn main() {
     let b = Bar { x: 5 };
diff --git a/src/test/ui/structs/struct-base-wrong-type.stderr b/src/test/ui/structs/struct-base-wrong-type.stderr
index 8519a9510a9..045eb610f7d 100644
--- a/src/test/ui/structs/struct-base-wrong-type.stderr
+++ b/src/test/ui/structs/struct-base-wrong-type.stderr
@@ -11,7 +11,7 @@ error[E0308]: mismatched types
   --> $DIR/struct-base-wrong-type.rs:14:35
    |
 LL | static foo_i: Foo = Foo { a: 2, ..4 }; //~  ERROR mismatched types
-   |                                   ^ expected struct `Foo`, found integral variable
+   |                                   ^ expected struct `Foo`, found integer
    |
    = note: expected type `Foo`
               found type `{integer}`
diff --git a/src/test/ui/structs/structure-constructor-type-mismatch.rs b/src/test/ui/structs/structure-constructor-type-mismatch.rs
index 54319e1ea4f..8850f6ea89f 100644
--- a/src/test/ui/structs/structure-constructor-type-mismatch.rs
+++ b/src/test/ui/structs/structure-constructor-type-mismatch.rs
@@ -16,32 +16,32 @@ fn main() {
     let pt = PointF {
         x: 1,
         //~^ ERROR mismatched types
-        //~| expected f32, found integral variable
+        //~| expected f32, found integer
         y: 2,
         //~^ ERROR mismatched types
-        //~| expected f32, found integral variable
+        //~| expected f32, found integer
     };
 
     let pt2 = Point::<f32> {
         x: 3,
         //~^ ERROR mismatched types
-        //~| expected f32, found integral variable
+        //~| expected f32, found integer
         y: 4,
         //~^ ERROR mismatched types
-        //~| expected f32, found integral variable
+        //~| expected f32, found integer
     };
 
     let pair = PairF {
         x: 5,
         //~^ ERROR mismatched types
-        //~| expected f32, found integral variable
+        //~| expected f32, found integer
         y: 6,
     };
 
     let pair2 = PairF::<i32> {
         x: 7,
         //~^ ERROR mismatched types
-        //~| expected f32, found integral variable
+        //~| expected f32, found integer
         y: 8,
     };
 
diff --git a/src/test/ui/structs/structure-constructor-type-mismatch.stderr b/src/test/ui/structs/structure-constructor-type-mismatch.stderr
index 6abc75110e1..3c1ed8e69a6 100644
--- a/src/test/ui/structs/structure-constructor-type-mismatch.stderr
+++ b/src/test/ui/structs/structure-constructor-type-mismatch.stderr
@@ -4,7 +4,7 @@ error[E0308]: mismatched types
 LL |         x: 1,
    |            ^
    |            |
-   |            expected f32, found integral variable
+   |            expected f32, found integer
    |            help: use a float literal: `1.0`
    |
    = note: expected type `f32`
@@ -16,7 +16,7 @@ error[E0308]: mismatched types
 LL |         y: 2,
    |            ^
    |            |
-   |            expected f32, found integral variable
+   |            expected f32, found integer
    |            help: use a float literal: `2.0`
    |
    = note: expected type `f32`
@@ -28,7 +28,7 @@ error[E0308]: mismatched types
 LL |         x: 3,
    |            ^
    |            |
-   |            expected f32, found integral variable
+   |            expected f32, found integer
    |            help: use a float literal: `3.0`
    |
    = note: expected type `f32`
@@ -40,7 +40,7 @@ error[E0308]: mismatched types
 LL |         y: 4,
    |            ^
    |            |
-   |            expected f32, found integral variable
+   |            expected f32, found integer
    |            help: use a float literal: `4.0`
    |
    = note: expected type `f32`
@@ -52,7 +52,7 @@ error[E0308]: mismatched types
 LL |         x: 5,
    |            ^
    |            |
-   |            expected f32, found integral variable
+   |            expected f32, found integer
    |            help: use a float literal: `5.0`
    |
    = note: expected type `f32`
@@ -64,7 +64,7 @@ error[E0308]: mismatched types
 LL |         x: 7,
    |            ^
    |            |
-   |            expected f32, found integral variable
+   |            expected f32, found integer
    |            help: use a float literal: `7.0`
    |
    = note: expected type `f32`
@@ -82,7 +82,7 @@ error[E0308]: mismatched types
 LL |         x: 9,  //~ ERROR mismatched types
    |            ^
    |            |
-   |            expected f32, found integral variable
+   |            expected f32, found integer
    |            help: use a float literal: `9.0`
    |
    = note: expected type `f32`
@@ -94,7 +94,7 @@ error[E0308]: mismatched types
 LL |         y: 10, //~ ERROR mismatched types
    |            ^^
    |            |
-   |            expected f32, found integral variable
+   |            expected f32, found integer
    |            help: use a float literal: `10.0`
    |
    = note: expected type `f32`
@@ -110,7 +110,7 @@ error[E0308]: mismatched types
   --> $DIR/structure-constructor-type-mismatch.rs:54:9
    |
 LL |         PointF::<u32> { .. } => {} //~ ERROR wrong number of type arguments
-   |         ^^^^^^^^^^^^^^^^^^^^ expected integral variable, found f32
+   |         ^^^^^^^^^^^^^^^^^^^^ expected integer, found f32
    |
    = note: expected type `Point<{integer}>`
               found type `Point<f32>`
@@ -119,7 +119,7 @@ error[E0308]: mismatched types
   --> $DIR/structure-constructor-type-mismatch.rs:59:9
    |
 LL |         PointF { .. } => {} //~ ERROR mismatched types
-   |         ^^^^^^^^^^^^^ expected integral variable, found f32
+   |         ^^^^^^^^^^^^^ expected integer, found f32
    |
    = note: expected type `Point<{integer}>`
               found type `Point<f32>`
@@ -128,7 +128,7 @@ error[E0308]: mismatched types
   --> $DIR/structure-constructor-type-mismatch.rs:67:9
    |
 LL |         PairF::<u32> { .. } => {} //~ ERROR mismatched types
-   |         ^^^^^^^^^^^^^^^^^^^ expected integral variable, found f32
+   |         ^^^^^^^^^^^^^^^^^^^ expected integer, found f32
    |
    = note: expected type `Pair<{integer}, {integer}>`
               found type `Pair<f32, u32>`
diff --git a/src/test/ui/try-block/try-block-type-error.stderr b/src/test/ui/try-block/try-block-type-error.stderr
index cf52c4ce152..0cbd737debd 100644
--- a/src/test/ui/try-block/try-block-type-error.stderr
+++ b/src/test/ui/try-block/try-block-type-error.stderr
@@ -4,7 +4,7 @@ error[E0271]: type mismatch resolving `<std::option::Option<f32> as std::ops::Tr
 LL |         42
    |         ^^
    |         |
-   |         expected f32, found integral variable
+   |         expected f32, found integer
    |         help: use a float literal: `42.0`
    |
    = note: expected type `f32`
diff --git a/src/test/ui/type/type-mismatch-multiple.rs b/src/test/ui/type/type-mismatch-multiple.rs
index f2e289a11b7..1904ccf5d59 100644
--- a/src/test/ui/type/type-mismatch-multiple.rs
+++ b/src/test/ui/type/type-mismatch-multiple.rs
@@ -4,7 +4,7 @@ fn main() { let a: bool = 1; let b: i32 = true; }
 //~^ ERROR mismatched types
 //~| expected type `bool`
 //~| found type `{integer}`
-//~| expected bool, found integral variable
+//~| expected bool, found integer
 //~| ERROR mismatched types
 //~| expected i32, found bool
 
diff --git a/src/test/ui/type/type-mismatch-multiple.stderr b/src/test/ui/type/type-mismatch-multiple.stderr
index b38579046b5..8f6b23ea091 100644
--- a/src/test/ui/type/type-mismatch-multiple.stderr
+++ b/src/test/ui/type/type-mismatch-multiple.stderr
@@ -2,7 +2,7 @@ error[E0308]: mismatched types
   --> $DIR/type-mismatch-multiple.rs:3:27
    |
 LL | fn main() { let a: bool = 1; let b: i32 = true; }
-   |                           ^ expected bool, found integral variable
+   |                           ^ expected bool, found integer
    |
    = note: expected type `bool`
               found type `{integer}`