]> git.lizzy.rs Git - rust.git/blobdiff - tests/ui/redundant_closure_call.stderr
iterate List by value
[rust.git] / tests / ui / redundant_closure_call.stderr
index 9c827fd8f17c616e482f64d73534441f1a1ceb84..68c1416bb6b1a33ff731f9fa9895116248011966 100644 (file)
@@ -12,12 +12,6 @@ error: Closure called just once immediately after it was declared
 LL |     i = closure(3);
    |     ^^^^^^^^^^^^^^
 
-error: Try not to call a closure in the expression where it is declared.
-  --> $DIR/redundant_closure_call.rs:4:13
-   |
-LL |     let a = (|| 42)();
-   |             ^^^^^^^^^ help: Try doing something like: : `42`
-
 error: Try not to call a closure in the expression where it is declared.
   --> $DIR/redundant_closure_call.rs:7:17
    |
@@ -30,5 +24,5 @@ error: Try not to call a closure in the expression where it is declared.
 LL |     k = (|a, b| a * b)(1, 5);
    |         ^^^^^^^^^^^^^^^^^^^^
 
-error: aborting due to 5 previous errors
+error: aborting due to 4 previous errors