rework compose implementation to not use retain stack
This commit is contained in:
parent
58c1f24161
commit
f40fd7eaa1
4 changed files with 19 additions and 6 deletions
2
std.grr
2
std.grr
|
|
@ -8,6 +8,8 @@ def eprintln { stderr fprint "\n" stderr fprint }
|
|||
def when { [] if }
|
||||
def unless { swap when }
|
||||
|
||||
def dip { swap [] curry compose call }
|
||||
def keep { over [call] dip }
|
||||
def bi { [keep] dip call }
|
||||
def tri { [[keep] dip keep] dip call }
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue