From 25e395653df2a91fc9a76dfd3ef050f1c7ba9fca Mon Sep 17 00:00:00 2001 From: Caio Date: Sun, 14 May 2023 09:49:20 -0300 Subject: Move tests --- tests/ui/for-loop-while/issue-1257.rs | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 tests/ui/for-loop-while/issue-1257.rs (limited to 'tests/ui/for-loop-while') diff --git a/tests/ui/for-loop-while/issue-1257.rs b/tests/ui/for-loop-while/issue-1257.rs new file mode 100644 index 00000000000..de5a6d35925 --- /dev/null +++ b/tests/ui/for-loop-while/issue-1257.rs @@ -0,0 +1,11 @@ +// run-pass +// pretty-expanded FIXME #23616 + +pub fn main () { + let mut line = "".to_string(); + let mut i = 0; + while line != "exit".to_string() { + line = if i == 9 { "exit".to_string() } else { "notexit".to_string() }; + i += 1; + } +} -- cgit 1.4.1-3-g733a5