]> git.proxmox.com Git - rustc.git/blame - src/test/ui/fmt/format-string-error.stderr
New upstream version 1.39.0+dfsg1
[rustc.git] / src / test / ui / fmt / format-string-error.stderr
CommitLineData
476ff2be 1error: invalid format string: expected `'}'` but string was terminated
0731742a 2 --> $DIR/format-string-error.rs:4:16
476ff2be 3 |
0531ce1d 4LL | println!("{");
0731742a
XL
5 | -^ expected `'}'` in format string
6 | |
7 | because of this opening brace
476ff2be
SL
8 |
9 = note: if you intended to print `{`, you can escape it using `{{`
476ff2be
SL
10
11error: invalid format string: unmatched `}` found
0731742a 12 --> $DIR/format-string-error.rs:7:15
476ff2be 13 |
0531ce1d 14LL | println!("}");
8faf50e0 15 | ^ unmatched `}` in format string
476ff2be
SL
16 |
17 = note: if you intended to print `}`, you can escape it using `}}`
476ff2be 18
94b46f34 19error: invalid format string: invalid argument name `_foo`
0731742a 20 --> $DIR/format-string-error.rs:9:23
94b46f34
XL
21 |
22LL | let _ = format!("{_foo}", _foo = 6usize);
23 | ^^^^ invalid argument name in format string
24 |
25 = note: argument names cannot start with an underscore
26
27error: invalid format string: invalid argument name `_`
0731742a 28 --> $DIR/format-string-error.rs:11:23
94b46f34
XL
29 |
30LL | let _ = format!("{_}", _ = 6usize);
31 | ^ invalid argument name in format string
32 |
33 = note: argument names cannot start with an underscore
34
35error: invalid format string: expected `'}'` but string was terminated
0731742a 36 --> $DIR/format-string-error.rs:13:23
94b46f34
XL
37 |
38LL | let _ = format!("{");
0731742a
XL
39 | -^ expected `'}'` in format string
40 | |
41 | because of this opening brace
94b46f34
XL
42 |
43 = note: if you intended to print `{`, you can escape it using `{{`
44
45error: invalid format string: unmatched `}` found
0731742a 46 --> $DIR/format-string-error.rs:15:22
94b46f34
XL
47 |
48LL | let _ = format!("}");
49 | ^ unmatched `}` in format string
50 |
51 = note: if you intended to print `}`, you can escape it using `}}`
52
532ac7d7 53error: invalid format string: expected `'}'`, found `'\'`
0731742a 54 --> $DIR/format-string-error.rs:17:23
94b46f34 55 |
532ac7d7 56LL | let _ = format!("{\}");
0731742a
XL
57 | -^ expected `}` in format string
58 | |
59 | because of this opening brace
60 |
61 = note: if you intended to print `{`, you can escape it using `{{`
94b46f34 62
8faf50e0 63error: invalid format string: expected `'}'` but string was terminated
0731742a 64 --> $DIR/format-string-error.rs:19:35
8faf50e0 65 |
532ac7d7 66LL | let _ = format!("\n\n\n{\n\n\n");
0731742a
XL
67 | - ^ expected `'}'` in format string
68 | |
69 | because of this opening brace
8faf50e0
XL
70 |
71 = note: if you intended to print `{`, you can escape it using `{{`
72
73error: invalid format string: expected `'}'` but string was terminated
0731742a 74 --> $DIR/format-string-error.rs:25:3
8faf50e0
XL
75 |
76LL | {"###);
0731742a
XL
77 | -^ expected `'}'` in format string
78 | |
79 | because of this opening brace
8faf50e0
XL
80 |
81 = note: if you intended to print `{`, you can escape it using `{{`
82
83error: invalid format string: expected `'}'` but string was terminated
0731742a 84 --> $DIR/format-string-error.rs:33:1
8faf50e0 85 |
0731742a
XL
86LL | {
87 | - because of this opening brace
8faf50e0 88LL |
0731742a 89LL | "###);
8faf50e0
XL
90 | ^ expected `'}'` in format string
91 |
92 = note: if you intended to print `{`, you can escape it using `{{`
93
94error: invalid format string: unmatched `}` found
0731742a 95 --> $DIR/format-string-error.rs:39:2
8faf50e0
XL
96 |
97LL | }
98 | ^ unmatched `}` in format string
99 |
100 = note: if you intended to print `}`, you can escape it using `}}`
101
102error: invalid format string: unmatched `}` found
0731742a 103 --> $DIR/format-string-error.rs:47:9
8faf50e0
XL
104 |
105LL | }
106 | ^ unmatched `}` in format string
107 |
108 = note: if you intended to print `}`, you can escape it using `}}`
109
110error: aborting due to 12 previous errors
476ff2be 111