diff --git a/src/parse/tokens.rs b/src/parse/tokens.rs index 0c125b4b..ca2cb74a 100644 --- a/src/parse/tokens.rs +++ b/src/parse/tokens.rs @@ -248,7 +248,7 @@ impl<'s> Tokens<'s> { // Parenthesis and hashtag. '[' | ']' | '{' | '}' | '#' | // Markup. - '*' | '_' | '=' | '~' | '`' | '$' => { + '~' | '*' | '_' | '`' | '$' | '=' | '-' | '.' => { self.s.eat_assert(c); NodeKind::Escape(c) } diff --git a/tests/ref/markup/escape.png b/tests/ref/markup/escape.png index 4d2b570e..3434d6e0 100644 Binary files a/tests/ref/markup/escape.png and b/tests/ref/markup/escape.png differ diff --git a/tests/typ/markup/escape.typ b/tests/typ/markup/escape.typ index 87d2b83a..6ec469c1 100644 --- a/tests/typ/markup/escape.typ +++ b/tests/typ/markup/escape.typ @@ -24,6 +24,9 @@ // Some code stuff in text. let f() , ; : | + - /= == 12 "string" +// Escaped dot. +10\. May + --- // Unicode codepoint does not exist. // Error: 1-11 invalid unicode escape sequence