From: Matthew Willis Date: Mon, 31 Mar 2008 00:58:47 +0000 (-0700) Subject: Updated extra/match to use bi@ instead of 2apply. Ran "peg" test for testing. X-Git-Tag: 0.94~3753^2 X-Git-Url: https://gitweb.factorcode.org/gitweb.cgi?p=factor.git;a=commitdiff_plain;h=a098790634503dfc03eb24969a4fbaff7f7512f5 Updated extra/match to use bi@ instead of 2apply. Ran "peg" test for testing. --- diff --git a/extra/match/match.factor b/extra/match/match.factor index dbc42f53e3..825d58c7c2 100755 --- a/extra/match/match.factor +++ b/extra/match/match.factor @@ -70,7 +70,7 @@ MACRO: match-cond ( assoc -- ) dup length zero? not [ 1 tail ] [ drop f ] if ; : (match-first) ( seq pattern-seq -- bindings leftover/f ) - 2dup [ length ] 2apply < [ 2drop f f ] + 2dup [ length ] bi@ < [ 2drop f f ] [ 2dup length head over match [ nip swap ?1-tail ] [ >r 1 tail r> (match-first) ] if*