Skip to content

Commit 23725a6

Browse files
authored
Rollup merge of rust-lang#34287 - durka:patch-26, r=steveklabnik
update reference for rust-lang#29734
2 parents db8a140 + b54afbe commit 23725a6

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

src/doc/reference.md

+13-5
Original file line numberDiff line numberDiff line change
@@ -114,12 +114,20 @@ Non-doc comments are interpreted as a form of whitespace.
114114

115115
## Whitespace
116116

117-
Whitespace is any non-empty string containing only the following characters:
118-
117+
Whitespace is any non-empty string containing only characters that have the
118+
`Pattern_White_Space` Unicode property, namely:
119+
120+
- `U+0009` (horizontal tab, `'\t'`)
121+
- `U+000A` (line feed, `'\n'`)
122+
- `U+000B` (vertical tab)
123+
- `U+000C` (form feed)
124+
- `U+000D` (carriage return, `'\r'`)
119125
- `U+0020` (space, `' '`)
120-
- `U+0009` (tab, `'\t'`)
121-
- `U+000A` (LF, `'\n'`)
122-
- `U+000D` (CR, `'\r'`)
126+
- `U+0085` (next line)
127+
- `U+200E` (left-to-right mark)
128+
- `U+200F` (right-to-left mark)
129+
- `U+2028` (line separator)
130+
- `U+2029` (paragraph separator)
123131

124132
Rust is a "free-form" language, meaning that all forms of whitespace serve only
125133
to separate _tokens_ in the grammar, and have no semantic significance.

0 commit comments

Comments
 (0)