diff options
| author | Marshall Lochbaum <mwlochbaum@gmail.com> | 2022-05-15 22:05:00 -0400 |
|---|---|---|
| committer | Marshall Lochbaum <mwlochbaum@gmail.com> | 2022-05-15 22:05:00 -0400 |
| commit | 5d06c6be4bea0f3b3d31d9f35a29f9a7460679a4 (patch) | |
| tree | a09abf07a85b60a0b637410fa826f101354a7edb | |
| parent | ade2f9fbb72bc960a053b6aebf6287977b099090 (diff) | |
Add help sections for modified assignment F↩
| -rw-r--r-- | docs/help/change.html | 12 | ||||
| -rw-r--r-- | docs/help/export.html | 4 | ||||
| -rw-r--r-- | help/change.md | 14 | ||||
| -rw-r--r-- | help/export.md | 4 |
4 files changed, 30 insertions, 4 deletions
diff --git a/docs/help/change.html b/docs/help/change.html index a4331332..172b4c58 100644 --- a/docs/help/change.html +++ b/docs/help/change.html @@ -18,3 +18,15 @@ <span class='Function'>⊢</span> <span class='Value'>b</span> <span class='Gets'>↩</span> <span class='String'>"Be the change you wish to see in the world."</span> "Be the change you wish to see in the world." </pre> +<h2 id="n-f-modify"><a class="header" href="#n-f-modify"><code><span class='Value'>n</span> <span class='Function'>F</span><span class='Gets'>↩</span></code>: Modify</a></h2> +<p><a class="fulldoc" href="../doc/expression.html#assignment">→full documentation</a></p> +<p>Apply function <code><span class='Function'>F</span></code> to existing variable <code><span class='Value'>n</span></code>, and assign the result back to <code><span class='Value'>n</span></code>.</p> +<a class="replLink" title="Open in the REPL" target="_blank" href="https://mlochbaum.github.io/BQN/try.html#code=4oqiIGIg4oy94oap">↗️</a><pre> <span class='Function'>⊢</span> <span class='Value'>b</span> <span class='Function'>⌽</span><span class='Gets'>↩</span> +".dlrow eht ni ees ot hsiw uoy egnahc eht eB" +</pre> +<h2 id="n-f-v-modify"><a class="header" href="#n-f-v-modify"><code><span class='Value'>n</span> <span class='Function'>F</span><span class='Gets'>↩</span> <span class='Value'>v</span></code>: Modify</a></h2> +<p><a class="fulldoc" href="../doc/expression.html#assignment">→full documentation</a></p> +<p>Assign <code><span class='Value'>n</span> <span class='Function'>F</span> <span class='Value'>v</span></code> to <code><span class='Value'>n</span></code>.</p> +<a class="replLink" title="Open in the REPL" target="_blank" href="https://mlochbaum.github.io/BQN/try.html#code=4oqiIGIg4oaTy5zihqkgNg==">↗️</a><pre> <span class='Function'>⊢</span> <span class='Value'>b</span> <span class='Function'>↓</span><span class='Modifier'>˜</span><span class='Gets'>↩</span> <span class='Number'>6</span> +" eht ni ees ot hsiw uoy egnahc eht eB" +</pre> diff --git a/docs/help/export.html b/docs/help/export.html index 0dcf8dd7..a693a7a6 100644 --- a/docs/help/export.html +++ b/docs/help/export.html @@ -14,9 +14,9 @@ <span class='Value'>ns.unexported</span> <span class='Error'>Error: No key found</span> </pre> -<h2 id="𝕨--export-names"><a class="header" href="#𝕨--export-names"><code><span class='Value'>𝕨</span> <span class='Gets'>⇐</span></code>: Export names</a></h2> +<h2 id="n--export-names"><a class="header" href="#n--export-names"><code><span class='Value'>n</span> <span class='Gets'>⇐</span></code>: Export names</a></h2> <p><a class="fulldoc" href="../doc/expression.html#exports">→full documentation</a></p> -<p>Export the names given in <code><span class='Value'>𝕩</span></code> from the current namespace. Names must be defined somewhere in the scope.</p> +<p>Export the names given in <code><span class='Value'>n</span></code> from the current namespace. Names must be defined somewhere in the scope.</p> <a class="replLink" title="Open in the REPL" target="_blank" href="https://mlochbaum.github.io/BQN/try.html#code=bnMxIOKGkCB7IOKfqGFsc29leHBvcnRlZOKfqeKHkCwgZXhwb3J0ZWQg4oeQIDUsIGFsc29leHBvcnRlZCDihpAgMH0KbnMxLmV4cG9ydGVkCm5zMS5hbHNvZXhwb3J0ZWQ=">↗️</a><pre> <span class='Value'>ns1</span> <span class='Gets'>←</span> <span class='Brace'>{</span> <span class='Bracket'>⟨</span><span class='Value'>alsoexported</span><span class='Bracket'>⟩</span><span class='Gets'>⇐</span><span class='Separator'>,</span> <span class='Value'>exported</span> <span class='Gets'>⇐</span> <span class='Number'>5</span><span class='Separator'>,</span> <span class='Value'>alsoexported</span> <span class='Gets'>←</span> <span class='Number'>0</span><span class='Brace'>}</span> <span class='Value'>ns1.exported</span> 5 diff --git a/help/change.md b/help/change.md index f5085d46..eb4dde8d 100644 --- a/help/change.md +++ b/help/change.md @@ -14,3 +14,17 @@ Variable `n` must already exist. ⊢ b ← 3 ⊢ b ↩ "Be the change you wish to see in the world." + +## `n F↩`: Modify +[→full documentation](../doc/expression.md#assignment) + +Apply function `F` to existing variable `n`, and assign the result back to `n`. + + ⊢ b ⌽↩ + +## `n F↩ v`: Modify +[→full documentation](../doc/expression.md#assignment) + +Assign `n F v` to `n`. + + ⊢ b ↓˜↩ 6 diff --git a/help/export.md b/help/export.md index 6b71fdb0..6f3970b2 100644 --- a/help/export.md +++ b/help/export.md @@ -11,10 +11,10 @@ Define a variable with name `n` and export it from the current namespace. ns.exported ns.unexported -## `𝕨 ⇐`: Export names +## `n ⇐`: Export names [→full documentation](../doc/expression.md#exports) -Export the names given in `𝕩` from the current namespace. Names must be defined somewhere in the scope. +Export the names given in `n` from the current namespace. Names must be defined somewhere in the scope. ns1 ← { ⟨alsoexported⟩⇐, exported ⇐ 5, alsoexported ← 0} ns1.exported |
