]> git.lizzy.rs Git - rust.git/blob - src/test/ui/type-alias-impl-trait/structural-match.rs
Auto merge of #84039 - jyn514:uplift-atomic-ordering, r=wesleywiser
[rust.git] / src / test / ui / type-alias-impl-trait / structural-match.rs
1 #![feature(const_impl_trait)]
2 #![feature(type_alias_impl_trait)]
3
4 type Foo = impl Send;
5
6 // This is not structural-match
7 struct A;
8
9 const fn value() -> Foo {
10     A
11 }
12 const VALUE: Foo = value();
13
14 fn test() {
15     match todo!() {
16         VALUE => (),
17         //~^ `impl Send` cannot be used in patterns
18         _ => (),
19     }
20 }
21
22 fn main() {}