]> git.proxmox.com Git - rustc.git/blob - src/test/ui/inference/str-as-char.stderr
New upstream version 1.67.1+dfsg1
[rustc.git] / src / test / ui / inference / str-as-char.stderr
1 error: character literal may only contain one codepoint
2 --> $DIR/str-as-char.rs:8:19
3 |
4 LL | let _: &str = '"""';
5 | ^^^^^
6 |
7 help: if you meant to write a `str` literal, use double quotes
8 |
9 LL | let _: &str = "\"\"\"";
10 | ~~~~~~~~
11
12 error: character literal may only contain one codepoint
13 --> $DIR/str-as-char.rs:9:19
14 |
15 LL | let _: &str = '\"\"\"';
16 | ^^^^^^^^
17 |
18 help: if you meant to write a `str` literal, use double quotes
19 |
20 LL | let _: &str = "\"\"\"";
21 | ~~~~~~~~
22
23 error[E0308]: mismatched types
24 --> $DIR/str-as-char.rs:7:19
25 |
26 LL | let _: &str = 'a';
27 | ---- ^^^ expected `&str`, found `char`
28 | |
29 | expected due to this
30 |
31 help: if you meant to write a `str` literal, use double quotes
32 |
33 LL | let _: &str = "a";
34 | ~~~
35
36 error: aborting due to 3 previous errors
37
38 For more information about this error, try `rustc --explain E0308`.