OSDN Git Service
(root)
/
joypy
/
Thun.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
33f34dd
)
Elegant definitions for un-, bin-, tern-ary combinators.
author
Simon Forman
<sforman@hushmail.com>
Wed, 13 Jun 2018 17:24:36 +0000
(10:24 -0700)
committer
Simon Forman
<sforman@hushmail.com>
Wed, 13 Jun 2018 17:24:36 +0000
(10:24 -0700)
joy/library.py
patch
|
blob
|
history
diff --git
a/joy/library.py
b/joy/library.py
index
0bafed9
..
f754093
100644
(file)
--- a/
joy/library.py
+++ b/
joy/library.py
@@
-103,9
+103,9
@@
disenstacken == ? [uncons ?] loop pop
? == dup truthy
dinfrirst == dip infra first
nullary == [stack] dinfrirst
-unary ==
[stack [pop] dip] dinfrirst
-binary ==
[stack [popop] dip] dinfrirst
-ternary ==
[stack [popop pop] dip] dinfrirst
+unary ==
nullary popd
+binary ==
nullary [popop] dip
+ternary ==
unary [popop] dip
pam == [i] map
run == [] swap infra
sqr == dup mul