about summary refs log tree commit diff
path: root/tests/ui/rfcs/rfc-1445-restrict-constants-in-patterns/cant-hide-behind-direct-struct-embedded.rs
diff options
context:
space:
mode:
authorEsteban Küber <esteban@kuber.com.ar>2024-11-20 04:06:39 +0000
committerEsteban Küber <esteban@kuber.com.ar>2024-12-04 20:29:36 +0000
commita6040bc230bc7b26f413d7fbf60402e6e7940192 (patch)
treee2a4dbce4cce22218605551440673daad935c98d /tests/ui/rfcs/rfc-1445-restrict-constants-in-patterns/cant-hide-behind-direct-struct-embedded.rs
parent253eb95d4582e1abffc4a74dd8eaccd5b94b5d6f (diff)
downloadrust-a6040bc230bc7b26f413d7fbf60402e6e7940192.tar.gz
rust-a6040bc230bc7b26f413d7fbf60402e6e7940192.zip
Specify type kind of constant that can't be used in patterns
```
error: trait object `dyn Send` cannot be used in patterns
  --> $DIR/issue-70972-dyn-trait.rs:6:9
   |
LL | const F: &'static dyn Send = &7u32;
   | -------------------------- constant defined here
...
LL |         F => panic!(),
   |         ^ trait object can't be used in patterns
```
Diffstat (limited to 'tests/ui/rfcs/rfc-1445-restrict-constants-in-patterns/cant-hide-behind-direct-struct-embedded.rs')
0 files changed, 0 insertions, 0 deletions