rust/tests/ui/redundant_closure_call_early.stderr

17 lines
513 B
Text
Raw Normal View History

error: try not to call a closure in the expression where it is declared
--> $DIR/redundant_closure_call_early.rs:9:17
2017-08-01 17:54:21 +02:00
|
2018-12-27 16:57:55 +01:00
LL | let mut k = (|m| m + 1)(i);
2018-12-10 06:27:19 +01:00
| ^^^^^^^^^^^^^^
|
= note: `-D clippy::redundant-closure-call` implied by `-D warnings`
2017-08-01 17:54:21 +02:00
error: try not to call a closure in the expression where it is declared
--> $DIR/redundant_closure_call_early.rs:12:9
2017-08-01 17:54:21 +02:00
|
2018-12-27 16:57:55 +01:00
LL | k = (|a, b| a * b)(1, 5);
2018-12-10 06:27:19 +01:00
| ^^^^^^^^^^^^^^^^^^^^
2017-08-01 17:54:21 +02:00
error: aborting due to 2 previous errors
2018-01-16 17:06:27 +01:00