remove spin from core and retire it to basis/shuffle
parent
6c48852fb0
commit
6e9d369331
|
@ -1,5 +1,6 @@
|
|||
USING: help.markup help.syntax ;
|
||||
IN: shuffle
|
||||
|
||||
HELP: spin $complex-shuffle ;
|
||||
HELP: roll $complex-shuffle ;
|
||||
HELP: -roll $complex-shuffle ;
|
||||
|
|
|
@ -22,6 +22,8 @@ MACRO: shuffle-effect ( effect -- )
|
|||
SYNTAX: shuffle(
|
||||
")" parse-effect suffix! \ shuffle-effect suffix! ;
|
||||
|
||||
: spin ( x y z -- z y x ) swap rot ; inline deprecated
|
||||
|
||||
: roll ( x y z t -- y z t x ) [ rot ] dip swap ; inline deprecated
|
||||
|
||||
: -roll ( x y z t -- t x y z ) swap [ -rot ] dip ; inline deprecated
|
||||
|
|
|
@ -63,7 +63,7 @@ TUPLE: predicate-engine class methods ;
|
|||
|
||||
C: <predicate-engine> predicate-engine
|
||||
|
||||
: push-method ( method specializer atomic assoc -- )
|
||||
: push-method ( specializer method atomic assoc -- )
|
||||
dupd [
|
||||
[ ] [ H{ } clone <predicate-engine> ] ?if
|
||||
[ methods>> set-at ] keep
|
||||
|
@ -71,7 +71,7 @@ C: <predicate-engine> predicate-engine
|
|||
|
||||
: flatten-method ( class method assoc -- )
|
||||
[ [ flatten-class keys ] keep ] 2dip [
|
||||
[ spin ] dip push-method
|
||||
[ swap rot ] dip push-method
|
||||
] 3curry each ;
|
||||
|
||||
: flatten-methods ( assoc -- assoc' )
|
||||
|
|
|
@ -8,8 +8,6 @@ DEFER: 2dip
|
|||
DEFER: 3dip
|
||||
|
||||
! Stack stuff
|
||||
: spin ( x y z -- z y x ) swap rot ; inline
|
||||
|
||||
: 2over ( x y z -- x y z x y ) pick pick ; inline
|
||||
|
||||
: clear ( -- ) { } set-datastack ;
|
||||
|
|
Loading…
Reference in New Issue