]> git.lizzy.rs Git - rust.git/blob - tests/ui/print_with_newline.rs
Adapt the *.stderr files of the ui-tests to the tool_lints
[rust.git] / tests / ui / print_with_newline.rs
1 #![feature(tool_lints)]
2
3 #![allow(clippy::print_literal)]
4 #![warn(clippy::print_with_newline)]
5
6 fn main() {
7     print!("Hello\n");
8     print!("Hello {}\n", "world");
9     print!("Hello {} {}\n", "world", "#2");
10     print!("{}\n", 1265);
11
12     // these are all fine
13     print!("");
14     print!("Hello");
15     println!("Hello");
16     println!("Hello\n");
17     println!("Hello {}\n", "world");
18     print!("Issue\n{}", 1265);
19     print!("{}", 1265);
20     print!("\n{}", 1275);
21     print!("\n\n");
22     print!("like eof\n\n");
23     print!("Hello {} {}\n\n", "world", "#2");
24 }