blob: a8085a786e1890ca66d0b2576ccee7663e145ad5 (
plain)
| 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
 | const fn failure() {
    panic!("{:?}", 0);
    //~^ ERROR cannot call non-const formatting macro in constant functions
}
const fn print() {
    println!("{:?}", 0);
    //~^ ERROR cannot call non-const formatting macro in constant functions
    //~| ERROR cannot call non-const function `_print` in constant functions
}
const fn format_args() {
    format_args!("{}", 0);
    //~^ ERROR cannot call non-const formatting macro in constant functions
}
fn main() {}
 |