fix rebase
This commit is contained in:
parent
b3517cdee7
commit
468722b33c
3 changed files with 4 additions and 39 deletions
|
@ -4,10 +4,8 @@ error[E0317]: if may be missing an else clause
|
||||||
LL | / if true {
|
LL | / if true {
|
||||||
LL | | return 0;
|
LL | | return 0;
|
||||||
LL | | }
|
LL | | }
|
||||||
| |_____^ expected (), found i32
|
| |_____^ expected `()`, found `i32`
|
||||||
|
|
|
|
||||||
= note: expected type `()`
|
|
||||||
found type `i32`
|
|
||||||
= note: `if` expressions without `else` evaluate to `()`
|
= note: `if` expressions without `else` evaluate to `()`
|
||||||
= help: consider adding an `else` block that evaluates to the expected type
|
= help: consider adding an `else` block that evaluates to the expected type
|
||||||
|
|
||||||
|
|
|
@ -33,10 +33,7 @@ error[E0308]: mismatched types
|
||||||
LL | extern fn bar() {
|
LL | extern fn bar() {
|
||||||
| - possibly return type missing here?
|
| - possibly return type missing here?
|
||||||
LL | 0
|
LL | 0
|
||||||
| ^ expected (), found integer
|
| ^ expected `()`, found integer
|
||||||
|
|
|
||||||
= note: expected type `()`
|
|
||||||
found type `{integer}`
|
|
||||||
|
|
||||||
error[E0308]: mismatched types
|
error[E0308]: mismatched types
|
||||||
--> $DIR/span-preservation.rs:44:5
|
--> $DIR/span-preservation.rs:44:5
|
||||||
|
@ -52,10 +49,7 @@ error[E0308]: mismatched types
|
||||||
LL | extern "Rust" fn rust_abi() {
|
LL | extern "Rust" fn rust_abi() {
|
||||||
| - possibly return type missing here?
|
| - possibly return type missing here?
|
||||||
LL | 0
|
LL | 0
|
||||||
| ^ expected (), found integer
|
| ^ expected `()`, found integer
|
||||||
|
|
|
||||||
= note: expected type `()`
|
|
||||||
found type `{integer}`
|
|
||||||
|
|
||||||
error[E0308]: mismatched types
|
error[E0308]: mismatched types
|
||||||
--> $DIR/span-preservation.rs:54:5
|
--> $DIR/span-preservation.rs:54:5
|
||||||
|
@ -63,10 +57,7 @@ error[E0308]: mismatched types
|
||||||
LL | extern "\x43" fn c_abi_escaped() {
|
LL | extern "\x43" fn c_abi_escaped() {
|
||||||
| - possibly return type missing here?
|
| - possibly return type missing here?
|
||||||
LL | 0
|
LL | 0
|
||||||
| ^ expected (), found integer
|
| ^ expected `()`, found integer
|
||||||
|
|
|
||||||
= note: expected type `()`
|
|
||||||
found type `{integer}`
|
|
||||||
|
|
||||||
error: aborting due to 8 previous errors
|
error: aborting due to 8 previous errors
|
||||||
|
|
||||||
|
|
|
@ -1,24 +0,0 @@
|
||||||
error[E0308]: mismatched types
|
|
||||||
--> $DIR/issue-30904.rs:20:45
|
|
||||||
|
|
|
||||||
LL | let _: for<'a> fn(&'a str) -> Str<'a> = Str;
|
|
||||||
| ^^^ expected concrete lifetime, found bound lifetime parameter 'a
|
|
||||||
|
|
|
||||||
= note: expected fn pointer `for<'a> fn(&'a str) -> Str<'a>`
|
|
||||||
found fn item `fn(&str) -> Str<'_> {Str::<'_>}`
|
|
||||||
|
|
||||||
error[E0631]: type mismatch in function arguments
|
|
||||||
--> $DIR/issue-30904.rs:26:10
|
|
||||||
|
|
|
||||||
LL | fn test<F: for<'x> FnOnce<(&'x str,)>>(_: F) {}
|
|
||||||
| ---- -------------------------- required by this bound in `test`
|
|
||||||
...
|
|
||||||
LL | struct Str<'a>(&'a str);
|
|
||||||
| ------------------------ found signature of `fn(&str) -> _`
|
|
||||||
...
|
|
||||||
LL | test(Str);
|
|
||||||
| ^^^ expected signature of `for<'x> fn(&'x str) -> _`
|
|
||||||
|
|
||||||
error: aborting due to 2 previous errors
|
|
||||||
|
|
||||||
For more information about this error, try `rustc --explain E0308`.
|
|
Loading…
Add table
Add a link
Reference in a new issue