]> git.lizzy.rs Git - rust.git/blobdiff - src/test/ui/parser/struct-literal-restrictions-in-lamda.stderr
:arrow_up: rust-analyzer
[rust.git] / src / test / ui / parser / struct-literal-restrictions-in-lamda.stderr
index b948ab2abb50870990fa355aa934d1086667c44f..0852c7cb4705d8c862bdf5ab4fd5ff69e8ddfdf7 100644 (file)
@@ -24,7 +24,13 @@ LL | |     }.hi() {
    | |__________^ expected `bool`, found closure
    |
    = note: expected type `bool`
-           found closure `[closure@$DIR/struct-literal-restrictions-in-lamda.rs:12:11: 14:11]`
+           found closure `[closure@$DIR/struct-literal-restrictions-in-lamda.rs:12:11: 12:13]`
+help: use parentheses to call this closure
+   |
+LL ~     while (|| Foo {
+LL |         x: 3
+LL ~     }.hi())() {
+   |
 
 error: aborting due to 2 previous errors