diff options
Diffstat (limited to 'tests/ui/uninhabited')
-rw-r--r-- | tests/ui/uninhabited/diverging-guard.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/ui/uninhabited/diverging-guard.rs b/tests/ui/uninhabited/diverging-guard.rs new file mode 100644 index 000000000..7d57cd51c --- /dev/null +++ b/tests/ui/uninhabited/diverging-guard.rs @@ -0,0 +1,10 @@ +// check-pass + +enum Void {} + +fn main() { + let x: Void; + match x { + _ if { loop {} } => (), + } +} |