diff options
| author | Marijn Haverbeke <marijnh@gmail.com> | 2011-11-22 12:47:07 +0100 |
|---|---|---|
| committer | Marijn Haverbeke <marijnh@gmail.com> | 2011-11-22 12:47:07 +0100 |
| commit | 532642f425a4e3c05d848299aec2b95e66e7909c (patch) | |
| tree | d7004fc25089a07e2dabc45595830e4a8cd262ad /doc/tutorial | |
| parent | bd16aac903357e30e1e3d3fe8390d6a6e2b7434c (diff) | |
Clarify escaped newlines in tutorial
Closes #1117
Diffstat (limited to 'doc/tutorial')
| -rw-r--r-- | doc/tutorial/syntax.md | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/doc/tutorial/syntax.md b/doc/tutorial/syntax.md index b9605ede85f..819df605d3a 100644 --- a/doc/tutorial/syntax.md +++ b/doc/tutorial/syntax.md @@ -240,7 +240,12 @@ character escapes, using the backslash character: String literals allow the same escape sequences. They are written between double quotes (`"hello"`). Rust strings may contain newlines. When a newline is preceded by a backslash, it, and all white space -following it, will not appear in the resulting string literal. +following it, will not appear in the resulting string literal. So +this is equivalent to `"abc"`: + + let s = "a\ + b\ + c"; ## Operators |
