about summary refs log tree commit diff
path: root/tests/ui/half-open-range-patterns/slice_pattern_syntax_problem2.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/half-open-range-patterns/slice_pattern_syntax_problem2.rs')
-rw-r--r--tests/ui/half-open-range-patterns/slice_pattern_syntax_problem2.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/ui/half-open-range-patterns/slice_pattern_syntax_problem2.rs b/tests/ui/half-open-range-patterns/slice_pattern_syntax_problem2.rs
new file mode 100644
index 00000000000..6e7df309491
--- /dev/null
+++ b/tests/ui/half-open-range-patterns/slice_pattern_syntax_problem2.rs
@@ -0,0 +1,10 @@
+// run-pass
+
+fn main() {
+    let xs = [13, 1, 5, 2, 3, 1, 21, 8];
+    if let [3..=14, ..] = xs {
+        /* this variant must pass for now, unfortunately.
+         * This test is included here to help inform a future plan for these.
+         */
+    };
+}