From 698f8c2f01ea549d77d7dc3338a12e04c11057b9 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:02:58 +0200 Subject: Adding upstream version 1.64.0+dfsg1. Signed-off-by: Daniel Baumann --- src/test/ui/resolve/bad-env-capture.stderr | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 src/test/ui/resolve/bad-env-capture.stderr (limited to 'src/test/ui/resolve/bad-env-capture.stderr') diff --git a/src/test/ui/resolve/bad-env-capture.stderr b/src/test/ui/resolve/bad-env-capture.stderr new file mode 100644 index 000000000..f78a38a3d --- /dev/null +++ b/src/test/ui/resolve/bad-env-capture.stderr @@ -0,0 +1,24 @@ +error[E0434]: can't capture dynamic environment in a fn item + --> $DIR/bad-env-capture.rs:4:27 + | +LL | fn bar() { log(debug, x); } + | ^ + | + = help: use the `|| { ... }` closure form instead + +error[E0425]: cannot find function `log` in this scope + --> $DIR/bad-env-capture.rs:4:16 + | +LL | fn bar() { log(debug, x); } + | ^^^ not found in this scope + +error[E0425]: cannot find value `debug` in this scope + --> $DIR/bad-env-capture.rs:4:20 + | +LL | fn bar() { log(debug, x); } + | ^^^^^ not found in this scope + +error: aborting due to 3 previous errors + +Some errors have detailed explanations: E0425, E0434. +For more information about an error, try `rustc --explain E0425`. -- cgit v1.2.3