fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #71365 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum4fb7144ed15

1.43.0
786 B24 linesraw
1error[E0434]: can't capture dynamic environment in a fn item
2  --> $DIR/bad-env-capture3.rs:4:31
3   |
4LL |         fn bar() { log(debug, x); }
5   |                               ^
6   |
7   = help: use the `|| { ... }` closure form instead
8
9error[E0425]: cannot find function `log` in this scope
10  --> $DIR/bad-env-capture3.rs:4:20
11   |
12LL |         fn bar() { log(debug, x); }
13   |                    ^^^ not found in this scope
14
15error[E0425]: cannot find value `debug` in this scope
16  --> $DIR/bad-env-capture3.rs:4:24
17   |
18LL |         fn bar() { log(debug, x); }
19   |                        ^^^^^ not found in this scope
20
21error: aborting due to 3 previous errors
22
23Some errors have detailed explanations: E0425, E0434.
24For more information about an error, try `rustc --explain E0425`.