💾 Archived View for oortcloud.flounder.online › junk › 3locals.gmi captured on 2024-02-05 at 09:23:32. Gemini links have been rewritten to link to archived content

View Raw

More Information

-=-=-=-=-=-=-

Prev

(:=) and (:) are normal binding

(a+a $ a: 1) == 2
(b $ b: 3*a // a: 1+1) == 6

x $ d // e <=> (x $ d) $ e

(<-) expands sequences and pattern matches

([x] $ x<-0,1,2) == [0],[1],[2]
([x] $ odd x<-0,1,2) == [1]

todo: better to explicitly zip or to use (x<-... :: y<-...) simultaneous def?

(::=) defines algebraic types

(Seq(Lit "a",Rep(Alt(Lit "b",Lit "c"))) $
    rx ::= Eps | Lit l | Seq(s,t) | Alt(p,q) | Rep(s))

Up