From 22a33e01325ba2331a6b28dfc3d466c119d0834c Mon Sep 17 00:00:00 2001 From: Marshall Lochbaum Date: Thu, 3 Sep 2020 22:25:59 -0400 Subject: Add the null character literal @ --- docs/doc/syntax.html | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'docs/doc/syntax.html') diff --git a/docs/doc/syntax.html b/docs/doc/syntax.html index aafb86d9..5fc5ff3a 100644 --- a/docs/doc/syntax.html +++ b/docs/doc/syntax.html @@ -25,6 +25,10 @@ Character or string literal +@ +Null character + + ¯∞π Used in numeric literals @@ -109,6 +113,7 @@ ¨ "a" 'a' # A string is an array but a character isn't ⟨ 1 0 ⟩ +

The null character (code point 0) has a dedicated literal representation @. This character can be used to directly convert between characters and numeric code points, which among many other uses allows tricky characters to be entered by code point: for example, a non-breaking space is @+160. The character can also be entered as a character literal, but this will display differently in various editors and some tools may have trouble with a file directly containing a null, so it is best to use @ instead.

Expressions

More discussion

Like APL, BQN uses four syntactic roles for values in expressions:

-- cgit v1.2.3