Skip to content

Commit 709f3c5

Browse files
committed
Update reference.md: string literals section
Remove the name "multi-line string literal" since the rule appears to affect each line-break individually rather than the whole string literal. Re-word, and remove the stray reference to raw strings.
1 parent f4ab2b3 commit 709f3c5

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/doc/reference.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -192,13 +192,13 @@ which must be _escaped_ by a preceding `U+005C` character (`\`).
192192

193193
A _string literal_ is a sequence of any Unicode characters enclosed within two
194194
`U+0022` (double-quote) characters, with the exception of `U+0022` itself,
195-
which must be _escaped_ by a preceding `U+005C` character (`\`), or a _raw
196-
string literal_.
195+
which must be _escaped_ by a preceding `U+005C` character (`\`).
197196

198-
A multi-line string literal may be defined by terminating each line with a
199-
`U+005C` character (`\`) immediately before the newline. This causes the
200-
`U+005C` character, the newline, and all whitespace at the beginning of the
201-
next line to be ignored.
197+
Line-break characters are allowed in string literals. Normally they represent
198+
themselves (i.e. no translation), but as a special exception, when a `U+005C`
199+
character (`\`) occurs immediately before the newline, the `U+005C` character,
200+
the newline, and all whitespace at the beginning of the next line are ignored.
201+
Thus `a` and `b` are equal:
202202

203203
```rust
204204
let a = "foobar";

0 commit comments

Comments
 (0)