]> gitweb.factorcode.org Git - factor.git/commitdiff
Fix bootstrap failure
authorSlava Pestov <slava@factorcode.org>
Mon, 22 Aug 2005 20:39:01 +0000 (20:39 +0000)
committerSlava Pestov <slava@factorcode.org>
Mon, 22 Aug 2005 20:39:01 +0000 (20:39 +0000)
library/alien/syntax.factor

index f89054c91f600fb455ea668e64084743b95d4708..d5f6944c1ae7589fe312cc1a569cc8e72ed004df 100644 (file)
@@ -22,8 +22,12 @@ USING: compiler kernel lists namespaces parser sequences words ;
 
 : LIBRARY: scan "c-library" set ; parsing
 
+: unpair ( seq -- odds evens )
+    2 swap group flip dup empty?
+    [ drop { } { } ] [ 2unseq ] ifte ;
+
 : parse-arglist ( lst -- types stack effect )
-    2 swap group flip 2unseq [
+    unpair [
         " " % [ "," ?tail drop % " " % ] each "-- " %
     ] make-string ;