rust/tests/ui/inference/char-as-str-multi.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

8 lines
237 B
Rust
Raw Normal View History

// When a MULTI/NO-character string literal is used where a char should be,
// DO NOT suggest changing to single quotes.
fn main() {
let _: char = "foo"; //~ ERROR mismatched types
let _: char = ""; //~ ERROR mismatched types
}