rust/tests/ui/builtin-type-shadow.stderr

23 lines
632 B
Plaintext
Raw Normal View History

2017-08-01 17:54:21 +02:00
error: This generic shadows the built-in type `u32`
--> $DIR/builtin-type-shadow.rs:5:8
|
2017-02-08 14:58:07 +01:00
5 | fn foo<u32>(a: u32) -> u32 {
| ^^^
|
2017-08-01 17:54:21 +02:00
= note: `-D builtin-type-shadow` implied by `-D warnings`
error[E0308]: mismatched types
--> $DIR/builtin-type-shadow.rs:6:5
|
2017-08-11 14:11:46 +02:00
5 | fn foo<u32>(a: u32) -> u32 {
| --- expected `u32` because of return type
2017-02-08 14:58:07 +01:00
6 | 42
| ^^ expected type parameter, found integral variable
|
= note: expected type `u32`
found type `{integer}`
2018-01-16 17:06:27 +01:00
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0308`.