diff options
Diffstat (limited to 'tests/ui/for-loop-while/issue-51345.rs')
-rw-r--r-- | tests/ui/for-loop-while/issue-51345.rs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/ui/for-loop-while/issue-51345.rs b/tests/ui/for-loop-while/issue-51345.rs new file mode 100644 index 000000000..15571e8bf --- /dev/null +++ b/tests/ui/for-loop-while/issue-51345.rs @@ -0,0 +1,8 @@ +// run-pass +#![allow(unreachable_code)] + +fn main() { + let mut v = Vec::new(); + + loop { v.push(break) } +} |