]> git.proxmox.com Git - rustc.git/blobdiff - src/test/ui/cast/cast-int-to-char.stderr
New upstream version 1.63.0+dfsg1
[rustc.git] / src / test / ui / cast / cast-int-to-char.stderr
index 55b9462db8df818e73bc23836bb26fa184ce2c81..ef606b6ae5fd4e5e687a7d72b615388b184373e3 100644 (file)
@@ -2,8 +2,15 @@ error[E0308]: mismatched types
   --> $DIR/cast-int-to-char.rs:4:16
    |
 LL |     foo::<u32>('0');
-   |                ^^^ expected `u32`, found `char`
+   |     ---------- ^^^ expected `u32`, found `char`
+   |     |
+   |     arguments to this function are incorrect
    |
+note: function defined here
+  --> $DIR/cast-int-to-char.rs:1:4
+   |
+LL | fn foo<T>(_t: T) {}
+   |    ^^^    -----
 help: you can cast a `char` to a `u32`, since a `char` always occupies 4 bytes
    |
 LL |     foo::<u32>('0' as u32);
@@ -13,8 +20,15 @@ error[E0308]: mismatched types
   --> $DIR/cast-int-to-char.rs:5:16
    |
 LL |     foo::<i32>('0');
-   |                ^^^ expected `i32`, found `char`
+   |     ---------- ^^^ expected `i32`, found `char`
+   |     |
+   |     arguments to this function are incorrect
+   |
+note: function defined here
+  --> $DIR/cast-int-to-char.rs:1:4
    |
+LL | fn foo<T>(_t: T) {}
+   |    ^^^    -----
 help: you can cast a `char` to an `i32`, since a `char` always occupies 4 bytes
    |
 LL |     foo::<i32>('0' as i32);
@@ -24,8 +38,15 @@ error[E0308]: mismatched types
   --> $DIR/cast-int-to-char.rs:6:16
    |
 LL |     foo::<u64>('0');
-   |                ^^^ expected `u64`, found `char`
+   |     ---------- ^^^ expected `u64`, found `char`
+   |     |
+   |     arguments to this function are incorrect
+   |
+note: function defined here
+  --> $DIR/cast-int-to-char.rs:1:4
    |
+LL | fn foo<T>(_t: T) {}
+   |    ^^^    -----
 help: you can cast a `char` to a `u64`, since a `char` always occupies 4 bytes
    |
 LL |     foo::<u64>('0' as u64);
@@ -35,8 +56,15 @@ error[E0308]: mismatched types
   --> $DIR/cast-int-to-char.rs:7:16
    |
 LL |     foo::<i64>('0');
-   |                ^^^ expected `i64`, found `char`
+   |     ---------- ^^^ expected `i64`, found `char`
+   |     |
+   |     arguments to this function are incorrect
    |
+note: function defined here
+  --> $DIR/cast-int-to-char.rs:1:4
+   |
+LL | fn foo<T>(_t: T) {}
+   |    ^^^    -----
 help: you can cast a `char` to an `i64`, since a `char` always occupies 4 bytes
    |
 LL |     foo::<i64>('0' as i64);
@@ -46,7 +74,15 @@ error[E0308]: mismatched types
   --> $DIR/cast-int-to-char.rs:8:17
    |
 LL |     foo::<char>(0u32);
-   |                 ^^^^ expected `char`, found `u32`
+   |     ----------- ^^^^ expected `char`, found `u32`
+   |     |
+   |     arguments to this function are incorrect
+   |
+note: function defined here
+  --> $DIR/cast-int-to-char.rs:1:4
+   |
+LL | fn foo<T>(_t: T) {}
+   |    ^^^    -----
 
 error: aborting due to 5 previous errors