From e858f41dffaee272ffcf4b2cb63a49ad25ebf7d7 Mon Sep 17 00:00:00 2001 From: Marshall Lochbaum Date: Mon, 15 Mar 2021 15:01:22 -0400 Subject: Highlight namespace dot as a separate token in md.bqn --- docs/doc/namespace.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'docs/doc/namespace.html') diff --git a/docs/doc/namespace.html b/docs/doc/namespace.html index 17ed7cf6..c6f19582 100644 --- a/docs/doc/namespace.html +++ b/docs/doc/namespace.html @@ -10,7 +10,7 @@

The following quick example shows a few ways to use a namespace returned by •Import:

ns  •Import "file.bqn"
 something, abbrabbreviation  ns  # Destructure
-ns.DoThing 6                         # Dot syntax
+ns.DoThing 6                         # Dot syntax
 

An here's how the contents of file.bqn might look in order to define the variables used above:

something, DoThing     # Declare exports
@@ -42,9 +42,9 @@
 

The arrows used for importing don't indicate that the surrounding block is a namespace or export variables. However, a single statement can both import and export, if it's a destructuring assignment and the main assignment arrow is .

two, vars  •Import "stuff.bqn"
 
-

The second way to get a value (just one at a time) from a namespace is dot syntax: write the namespace, then a dot ., then another name.

+

The second way to get a value (just one at a time) from a namespace is dot syntax: write the namespace, then a dot ., then another name.

example.b
 
-{n7}.n
+{n7}.n
 

The syntax is any subject followed by a dot and then a name. This can be chained like a.b.c if a namespace has a value that is also a namespace (and so on).

-- cgit v1.2.3