aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorMarshall Lochbaum <mwlochbaum@gmail.com>2022-05-07 07:41:21 -0400
committerMarshall Lochbaum <mwlochbaum@gmail.com>2022-05-07 07:41:21 -0400
commit441db9fd212a8770008807641b6bc43f1ce431e6 (patch)
treedbb3a57e3835a78357fbb4c3a75dde46c0796f1d /doc
parente79a95cc742bfd3d3ccc7baba7e0595403203e38 (diff)
Correct Switch definition (fixes #66)
Diffstat (limited to 'doc')
-rw-r--r--doc/control.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/control.md b/doc/control.md
index b7e58436..fe2e77e9 100644
--- a/doc/control.md
+++ b/doc/control.md
@@ -19,7 +19,7 @@ The useful control structures introduced here are collected as shortened definit
# Switch/case statements have many variations; these are a few
Match ← {𝕏𝕨}Β΄
Select ← {(βŠ‘π•©)β—Ά(1↓𝕩)@}
- Switch ← {cβ†βŠ‘π•© β‹„ mβ€Ώa←<Λ˜β‰βˆ˜β€Ώ2β₯Š1↓𝕩 β‹„ (βŠ‘a⊐C)β—Άm@}
+ Switch ← {cβ†βŠ‘π•© β‹„ mβ€Ώa←<Λ˜β‰βˆ˜β€Ώ2β₯Š1↓𝕩 β‹„ (m⊸⊐⌾<C)β—Άa@}
Test ← {fn←{Cβ€ΏAπ•Še:Cβ—ΆAβ€ΏE}´𝕩⋄Fn@}
## Blocks and functions
@@ -153,7 +153,7 @@ A simplified version of a switch-case statement is possible if the cases are nat
To test against other possible values, the following statement takes interleaved lists of values and actions, and disentangles them. It searches through the values with `⊐`.
- Switch ← {cβ†βŠ‘π•© β‹„ mβ€Ώa←<Λ˜β‰βˆ˜β€Ώ2β₯Š1↓𝕩 β‹„ (βŠ‘a⊐C)β—Άm@}
+ Switch ← {cβ†βŠ‘π•© β‹„ mβ€Ώa←<Λ˜β‰βˆ˜β€Ώ2β₯Š1↓𝕩 β‹„ (m⊸⊐⌾<C)β—Άa@}
Switch ⟨value
"increment" β‹„ {𝕀⋄ v+↩1}