Skip to content

Commit

Permalink
Document: don't allow characters with unicode property Bidi_Class in …
Browse files Browse the repository at this point in the history
…source files

Update documentation with changes made in scala#10017
  • Loading branch information
danarmak committed Oct 31, 2022
1 parent f8a5497 commit d874f79
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions spec/01-lexical-syntax.md
Expand Up @@ -8,6 +8,11 @@ chapter: 1

Scala source code consists of Unicode text.

The nine [Bidirectional explicit formatting](https://www.unicode.org/reports/tr9/#Bidirectional_Character_Types)
characters `\u202a - \u202e` and `\u2066 - \u2069` (inclusive) are forbidden
from appearing in source files. Note that they can be represented using
unicode escapes in string and character literals.

The program text is tokenized as described in this chapter.
See the last section for special support for XML literals,
which are parsed in _XML mode_.
Expand Down
5 changes: 5 additions & 0 deletions spec/13-syntax-summary.md
Expand Up @@ -8,6 +8,11 @@ chapter: 13

The following descriptions of Scala tokens uses literal characters `‘c’` when referring to the ASCII fragment `\u0000``\u007F`.

The nine [Bidirectional explicit formatting](https://www.unicode.org/reports/tr9/#Bidirectional_Character_Types)
characters `\u202a - \u202e` and `\u2066 - \u2069` (inclusive) are forbidden
from appearing in source files. Note that they can be represented using
unicode escapes in string and character literals.

## Lexical Syntax

The lexical syntax of Scala is given by the following grammar in EBNF form:
Expand Down

0 comments on commit d874f79

Please sign in to comment.