diff options
| author | Marshall Lochbaum <mwlochbaum@gmail.com> | 2020-09-03 22:15:24 -0400 |
|---|---|---|
| committer | Marshall Lochbaum <mwlochbaum@gmail.com> | 2020-09-03 22:15:24 -0400 |
| commit | ceaa82c6d1564b2ca7965c4f29b51f45ad1c2933 (patch) | |
| tree | c49c0e9c48abf57a82b0bc5d197a2f7421a8167a /docs/doc/syntax.html | |
| parent | af948faa3d79ae682d971c71704f9334cf8e847f (diff) | |
Highlight quotes as strings even if unpaired
Diffstat (limited to 'docs/doc/syntax.html')
| -rw-r--r-- | docs/doc/syntax.html | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/doc/syntax.html b/docs/doc/syntax.html index 42fe714a..aafb86d9 100644 --- a/docs/doc/syntax.html +++ b/docs/doc/syntax.html @@ -21,7 +21,7 @@ <td><a href="#comments">Comment</a></td> </tr> <tr> -<td><code>'"</code></td> +<td><code><span class='String'>'"</span></code></td> <td><a href="#constants">Character or string literal</a></td> </tr> <tr> @@ -102,7 +102,7 @@ <a class="replLink" title="Open in the REPL" target="_blank" href="https://mlochbaum.github.io/BQN/try.html#code=4p+oIMKvz4Ag4ouEIDAuNSDii4QgNWXCrzEg4ouEIDEuNUUzIOKLhCDiiJ4g4p+pICAgIyBBIGxpc3Qgb2YgbnVtYmVycw==&run">↗️</a><pre> <span class='Bracket'>⟨</span> <span class='Number'>¯π</span> <span class='Separator'>⋄</span> <span class='Number'>0.5</span> <span class='Separator'>⋄</span> <span class='Number'>5e¯1</span> <span class='Separator'>⋄</span> <span class='Number'>1.5E3</span> <span class='Separator'>⋄</span> <span class='Number'>∞</span> <span class='Bracket'>⟩</span> <span class='Comment'># A list of numbers </span>⟨ ¯3.14159265358979 0.5 0.5 1500 ∞ ⟩ </pre> -<p>Strings are written with double quotes <code><span class='String'>""</span></code>, and characters with single quotes <code>''</code> with a single character in between. A double quote within a string can be escaped by writing it twice; if two string literals are next to each other, they must be separated by a space. In contrast, character literals do not use escapes, as the length is already known.</p> +<p>Strings are written with double quotes <code><span class='String'>""</span></code>, and characters with single quotes <code><span class='String'>''</span></code> with a single character in between. A double quote within a string can be escaped by writing it twice; if two string literals are next to each other, they must be separated by a space. In contrast, character literals do not use escapes, as the length is already known.</p> <a class="replLink" title="Open in the REPL" target="_blank" href="https://mlochbaum.github.io/BQN/try.html#code=4omgwqgg4p+oICJzdHIiIOKLhCAicyd0IiJyIiDii4QgJ2MnIOKLhCAnJycg4ouEICciJyDin6kgICAjICIiIGlzIGFuIGVzY2FwZQoK4omhwqgg4p+oICJhIiDii4QgJ2EnIOKfqSAgICMgQSBzdHJpbmcgaXMgYW4gYXJyYXkgYnV0IGEgY2hhcmFjdGVyIGlzbid0&run">↗️</a><pre> <span class='Function'>≠</span><span class='Modifier'>¨</span> <span class='Bracket'>⟨</span> <span class='String'>"str"</span> <span class='Separator'>⋄</span> <span class='String'>"s't""r"</span> <span class='Separator'>⋄</span> <span class='String'>'c'</span> <span class='Separator'>⋄</span> <span class='String'>'''</span> <span class='Separator'>⋄</span> <span class='String'>'"'</span> <span class='Bracket'>⟩</span> <span class='Comment'># "" is an escape </span>⟨ 3 5 1 1 1 ⟩ |
