diff options
| author | Marshall Lochbaum <mwlochbaum@gmail.com> | 2021-01-06 21:36:29 -0500 |
|---|---|---|
| committer | Marshall Lochbaum <mwlochbaum@gmail.com> | 2021-01-06 21:50:27 -0500 |
| commit | 21188149724b1e5d418f3242fe4ccbde5eedfba3 (patch) | |
| tree | 755f8f96d8e3af1743623faa7801df9c3292c88d /src | |
| parent | 1a7d407ce2c5be64711686c94528ae31adaea400 (diff) | |
Avoid using ∾ to join units in BQN sources
Diffstat (limited to 'src')
| -rw-r--r-- | src/c.bqn | 2 | ||||
| -rw-r--r-- | src/f.bqn | 4 |
2 files changed, 3 insertions, 3 deletions
@@ -71,7 +71,7 @@ Tokenize←{ p←≠`1¨sb←¯1↓1↓/1(∾≠∾˜)t=sep # Separator group boundaries (excludes leading and trailing) sk←sb/˜p>∨⟜«(p+(sb-p)⊏t)∊3‿5+⊑bB # Keep the first of each group that's not just inside a bracket t{ie/˜↩𝕨⋄𝕨Fs𝕩}˜↩1¨⌾(sk⊸⊏)t≠sep # Remove the rest - r←ir⌾((t M vi∾≠⊑k)⊸/)(vi⌊t)⊏charRole∾0 # Role + r←ir⌾((t M vi≍≠⊑k)⊸/)(vi⌊t)⊏charRole∾0 # Role t+↩5×t M⟨⊑bI,5⟩ # Case-insensitive special names ⟨t,r,k,is,ie⟩ } @@ -50,7 +50,7 @@ s ← ≢¨ 𝕩 w ← (0<=)◶⟨⥊,⌈˝⍟(=-1˙)⟩1⊑¨s h ← ⌈˝⎉1⍟(0<=) ⊑¨s - o ← <∘∾⎉2 ≍⍟(0⌈2-=) (h ∾⌜ 𝕨×w¬(-𝕨×≠w)↑1) ↑¨ 𝕩 + o ← <∘∾⎉2 ≍⍟(0⌈2-=) (h ≍⌜ 𝕨×w¬(-𝕨×≠w)↑1) ↑¨ 𝕩 2 PadH (1⊸⌽⊸≡⥊h)◶⟨PadVMixed,PadV∘>⟩ o } @@ -60,13 +60,13 @@ FmtSimple ← (≠(0⊸<+≤)+´)∘(⥊<@˙)◶{ # Depth 1 # All characters + r ← =𝕩 ⋄ 𝕩 ↩ 0↓𝕩 k ← ∞⍟(0⊸=) -≠ c ← ¯1↓≢𝕩 q ← '"' # Escape quotes in strings (rank 1) and substitute control chars # with control pictures for other ranks. CSub ← { 𝕩 + (𝕩(=×'␡'-⊢)@+127) + ('␀'-@)×𝕩<@+32 } 𝕩 ↩ (1≠=)◶⟨(1+q=⊢)⊸/,Csub⟩ 𝕩 - r ← =𝕩 (r Enframe 1 PadH PadV)⍟(1≠r) ≍ (q⌾⊑c⥊(¯1⊑1∾c)↑'·') ∾⎉k 𝕩 ∾⎉k c-⊸↑q }‿{ # Not homogeneous, or empty |
