We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8631e1c commit 50ffd6bCopy full SHA for 50ffd6b
src/test/ui/pattern/issue-72565.rs
@@ -0,0 +1,8 @@
1
+const F: &'static dyn PartialEq<u32> = &7u32;
2
+
3
+fn main() {
4
+ let a: &dyn PartialEq<u32> = &7u32;
5
+ match a {
6
+ F => panic!(), //~ ERROR: `&dyn PartialEq<u32>` cannot be used in patterns
7
+ }
8
+}
src/test/ui/pattern/issue-72565.stderr
+error: `&dyn PartialEq<u32>` cannot be used in patterns
+ --> $DIR/issue-72565.rs:6:9
+ |
+LL | F => panic!(),
+ | ^
+error: aborting due to previous error
0 commit comments