]> gitweb.factorcode.org Git - factor.git/commitdiff
heaps: whoops, this was an error.
authorJohn Benediktsson <mrjbq7@gmail.com>
Mon, 1 Dec 2014 06:30:15 +0000 (22:30 -0800)
committerJohn Benediktsson <mrjbq7@gmail.com>
Mon, 1 Dec 2014 06:30:15 +0000 (22:30 -0800)
basis/heaps/heaps.factor

index 109d96bd5196732cde6ae1e80b92b9fdd7378535..dccf1e5e5500542f82130dd3df8a1efed50a0fb2 100644 (file)
@@ -181,7 +181,7 @@ M: heap heap-pop ( heap -- value key )
 
 : heap-pop-all ( heap -- alist )
     [ dup heap-empty? not ]
-    [ [ heap-pop ] keep 2array ]
+    [ dup heap-pop swap 2array ]
     produce nip ;
 
 ERROR: not-a-heap obj ;