Skip to content

Commit 2995104

Browse files
authored
Merge pull request #1180 from GrishaVar/hash-upper-bound-patch
Upper bound on hashes in raw string literals
2 parents d5618e8 + 76c534c commit 2995104

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

src/tokens.md

+11-11
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,16 @@ Literals are tokens used in [literal expressions].
2424

2525
#### Characters and strings
2626

27-
| | Example | `#` sets | Characters | Escapes |
28-
|----------------------------------------------|-----------------|-------------|-------------|---------------------|
29-
| [Character](#character-literals) | `'H'` | 0 | All Unicode | [Quote](#quote-escapes) & [ASCII](#ascii-escapes) & [Unicode](#unicode-escapes) |
30-
| [String](#string-literals) | `"hello"` | 0 | All Unicode | [Quote](#quote-escapes) & [ASCII](#ascii-escapes) & [Unicode](#unicode-escapes) |
31-
| [Raw string](#raw-string-literals) | `r#"hello"#` | 0 or more\* | All Unicode | `N/A` |
32-
| [Byte](#byte-literals) | `b'H'` | 0 | All ASCII | [Quote](#quote-escapes) & [Byte](#byte-escapes) |
33-
| [Byte string](#byte-string-literals) | `b"hello"` | 0 | All ASCII | [Quote](#quote-escapes) & [Byte](#byte-escapes) |
34-
| [Raw byte string](#raw-byte-string-literals) | `br#"hello"#` | 0 or more\* | All ASCII | `N/A` |
27+
| | Example | `#` sets\* | Characters | Escapes |
28+
|----------------------------------------------|-----------------|------------|-------------|---------------------|
29+
| [Character](#character-literals) | `'H'` | 0 | All Unicode | [Quote](#quote-escapes) & [ASCII](#ascii-escapes) & [Unicode](#unicode-escapes) |
30+
| [String](#string-literals) | `"hello"` | 0 | All Unicode | [Quote](#quote-escapes) & [ASCII](#ascii-escapes) & [Unicode](#unicode-escapes) |
31+
| [Raw string](#raw-string-literals) | `r#"hello"#` | <256 | All Unicode | `N/A` |
32+
| [Byte](#byte-literals) | `b'H'` | 0 | All ASCII | [Quote](#quote-escapes) & [Byte](#byte-escapes) |
33+
| [Byte string](#byte-string-literals) | `b"hello"` | 0 | All ASCII | [Quote](#quote-escapes) & [Byte](#byte-escapes) |
34+
| [Raw byte string](#raw-byte-string-literals) | `br#"hello"#` | <256 | All ASCII | `N/A` |
3535

36-
\* The number of `#`s on each side of the same literal must be equivalent
36+
\* The number of `#`s on each side of the same literal must be equivalent.
3737

3838
#### ASCII escapes
3939

@@ -193,7 +193,7 @@ following forms:
193193
> &nbsp;&nbsp; | `#` RAW_STRING_CONTENT `#`
194194
195195
Raw string literals do not process any escapes. They start with the character
196-
`U+0072` (`r`), followed by zero or more of the character `U+0023` (`#`) and a
196+
`U+0072` (`r`), followed by fewer than 256 of the character `U+0023` (`#`) and a
197197
`U+0022` (double-quote) character. The _raw string body_ can contain any sequence
198198
of Unicode characters and is terminated only by another `U+0022` (double-quote)
199199
character, followed by the same number of `U+0023` (`#`) characters that preceded
@@ -284,7 +284,7 @@ following forms:
284284
> &nbsp;&nbsp; _any ASCII (i.e. 0x00 to 0x7F)_
285285
286286
Raw byte string literals do not process any escapes. They start with the
287-
character `U+0062` (`b`), followed by `U+0072` (`r`), followed by zero or more
287+
character `U+0062` (`b`), followed by `U+0072` (`r`), followed by fewer than 256
288288
of the character `U+0023` (`#`), and a `U+0022` (double-quote) character. The
289289
_raw string body_ can contain any sequence of ASCII characters and is terminated
290290
only by another `U+0022` (double-quote) character, followed by the same number of

0 commit comments

Comments
 (0)