Update format string tests to explicitly escape multiple newlines
From what I can tell, the goal of the tests is to ensure that the error formatting is correct. I think this is still being tested as intended after this change.
This commit is contained in:
parent
a03fbfe2ff
commit
2dff700c4f
@ -5,7 +5,7 @@ fn main() {
|
|||||||
a");
|
a");
|
||||||
//~^ ERROR invalid format string
|
//~^ ERROR invalid format string
|
||||||
format!("{ \
|
format!("{ \
|
||||||
|
\
|
||||||
b");
|
b");
|
||||||
//~^ ERROR invalid format string
|
//~^ ERROR invalid format string
|
||||||
format!(r#"{ \
|
format!(r#"{ \
|
||||||
@ -38,12 +38,12 @@ fn main() {
|
|||||||
{ \
|
{ \
|
||||||
\
|
\
|
||||||
b \
|
b \
|
||||||
|
\
|
||||||
");
|
");
|
||||||
//~^^^ ERROR invalid format string
|
//~^^^ ERROR invalid format string
|
||||||
format!(r#"
|
format!(r#"
|
||||||
raw { \
|
raw { \
|
||||||
|
\
|
||||||
c"#);
|
c"#);
|
||||||
//~^^^ ERROR invalid format string
|
//~^^^ ERROR invalid format string
|
||||||
format!(r#"
|
format!(r#"
|
||||||
|
@ -19,7 +19,7 @@ error: invalid format string: expected `'}'`, found `'b'`
|
|||||||
|
|
|
|
||||||
LL | format!("{ \
|
LL | format!("{ \
|
||||||
| - because of this opening brace
|
| - because of this opening brace
|
||||||
LL |
|
LL | \
|
||||||
LL | b");
|
LL | b");
|
||||||
| ^ expected `}` in format string
|
| ^ expected `}` in format string
|
||||||
|
|
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user