summaryrefslogtreecommitdiffstats
path: root/tests/ui/macros/issue-86865.rs
blob: 01e0a20a5115c125731bea5af0eae8534b53df0e (plain)
1
2
3
4
5
6
7
8
9
10
11
use std::fmt::Write;

fn main() {
    println!(b"foo");
    //~^ ERROR format argument must be a string literal
    //~| HELP consider removing the leading `b`
    let mut s = String::new();
    write!(s, b"foo{}", "bar");
    //~^ ERROR format argument must be a string literal
    //~| HELP consider removing the leading `b`
}