summaryrefslogtreecommitdiffstats
path: root/src/test/ui/inline-const/const-match-pat-inference.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/inline-const/const-match-pat-inference.rs')
-rw-r--r--src/test/ui/inline-const/const-match-pat-inference.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/test/ui/inline-const/const-match-pat-inference.rs b/src/test/ui/inline-const/const-match-pat-inference.rs
new file mode 100644
index 000000000..d83ae6e98
--- /dev/null
+++ b/src/test/ui/inline-const/const-match-pat-inference.rs
@@ -0,0 +1,12 @@
+// check-pass
+
+#![feature(inline_const_pat)]
+#![allow(incomplete_features)]
+
+fn main() {
+ match 1u64 {
+ 0 => (),
+ const { 0 + 1 } => (),
+ const { 2 - 1 } ..= const { u64::MAX } => (),
+ }
+}