aboutsummaryrefslogtreecommitdiff
path: root/test/cases/variable_shadowing.3.zig
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2023-02-18 11:44:38 -0700
committerAndrew Kelley <andrew@ziglang.org>2023-02-18 19:17:21 -0700
commit8c96d0dddddfb4cd597661ff47551fcaf67cbf39 (patch)
tree4851da7ab2584ff1776e18e6886211a443a3e95f /test/cases/variable_shadowing.3.zig
parentb6a5e52decf4494d9506caa929139b630ce08dea (diff)
downloadzig-8c96d0dddddfb4cd597661ff47551fcaf67cbf39.tar.gz
zig-8c96d0dddddfb4cd597661ff47551fcaf67cbf39.zip
update test-cases for new for loop syntax
Diffstat (limited to 'test/cases/variable_shadowing.3.zig')
-rw-r--r--test/cases/variable_shadowing.3.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/cases/variable_shadowing.3.zig b/test/cases/variable_shadowing.3.zig
index 1e22ccf123..3d899e72cc 100644
--- a/test/cases/variable_shadowing.3.zig
+++ b/test/cases/variable_shadowing.3.zig
@@ -1,10 +1,10 @@
pub fn main() void {
var i = 0;
- for ("n") |_, i| {
+ for ("n", 0..) |_, i| {
}
}
// error
//
-// :3:19: error: loop index capture 'i' shadows local variable from outer scope
+// :3:24: error: capture 'i' shadows local variable from outer scope
// :2:9: note: previous declaration here