summaryrefslogtreecommitdiffstats
path: root/src/test/ui/rfc-2497-if-let-chains/no-double-assigments.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/test/ui/rfc-2497-if-let-chains/no-double-assigments.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/test/ui/rfc-2497-if-let-chains/no-double-assigments.rs b/src/test/ui/rfc-2497-if-let-chains/no-double-assigments.rs
new file mode 100644
index 000000000..6b91c455e
--- /dev/null
+++ b/src/test/ui/rfc-2497-if-let-chains/no-double-assigments.rs
@@ -0,0 +1,9 @@
+// check-pass
+
+fn main() {
+ loop {
+ // [1][0] should leave top scope
+ if true && [1][0] == 1 && true {
+ }
+ }
+}