]> git.lizzy.rs Git - rust.git/blob - src/test/ui/panics/panic-2021.rs
Rollup merge of #90498 - joshtriplett:target-tier-policy-draft-updates, r=Mark-Simulacrum
[rust.git] / src / test / ui / panics / panic-2021.rs
1 // edition:2021
2
3 fn main() {
4     panic!(123); //~ ERROR: format argument must be a string literal
5     panic!("{}"); //~ ERROR: 1 positional argument in format string
6     core::panic!("{}"); //~ ERROR: 1 positional argument in format string
7     assert!(false, 123); //~ ERROR: format argument must be a string literal
8     assert!(false, "{}"); //~ ERROR: 1 positional argument in format string
9 }