diff options
Diffstat (limited to 'tests/ui/block-result/block-must-not-have-result-while.rs')
-rw-r--r-- | tests/ui/block-result/block-must-not-have-result-while.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/ui/block-result/block-must-not-have-result-while.rs b/tests/ui/block-result/block-must-not-have-result-while.rs new file mode 100644 index 000000000..418059bf2 --- /dev/null +++ b/tests/ui/block-result/block-must-not-have-result-while.rs @@ -0,0 +1,6 @@ +fn main() { + while true { //~ WARN denote infinite loops with + true //~ ERROR mismatched types + //~| expected `()`, found `bool` + } +} |