Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recommend not escaping all the things #793

Merged
merged 2 commits into from
May 20, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions spec/syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -943,6 +943,15 @@ escaped-char = backslash ( backslash / "{" / "|" / "}" )
backslash = %x5C ; U+005C REVERSE SOLIDUS "\"
```

> [!NOTE]
> The `escaped-char` rule allows escaping some characters in places where
> they do not need to be escaped, such as braces in a _quoted_ _literal_.
> For example, `|foo {bar}|` and `|foo \{bar\}|` are synonymous.

When programmatically emitting message syntax,
only characters that are lexically meaningful in the current context
SHOULD be escaped.
eemeli marked this conversation as resolved.
Show resolved Hide resolved

### Whitespace

**_<dfn>Whitespace</dfn>_** is defined as one or more of
Expand Down