Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix (1,2).iterator; turns out you can not just pass Iterators to a sl…
…urpy function. Also fix a thinko with list flattening
  • Loading branch information
sorear committed Jul 20, 2010
1 parent b4172a2 commit fa2393d
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions setting
Expand Up @@ -439,7 +439,9 @@ my class Parcel {
my $ix = ($ll.elems - 1);
while $ix >= 0 {
$it = Iterator.RAWCREATE("valid", 1, "next", $it);
my $nit = Iterator.RAWCREATE("valid", 1, "next", Any);
$nit.next = $it;
$it = $nit;
Q:CgOp {
(prog
[setindex value (getfield slots
Expand Down Expand Up @@ -489,8 +491,10 @@ my class List is Cool {
}
# we can't push anything onto items because it might be
# EMPTY
$r.unshift($v.value);
$r.unshift($v.next);
if ! $v.value.^isa(EMPTY) {
$r.unshift($v.value);
$r.unshift($v.next);
}
} else {
$i.push($v);
}
Expand Down

0 comments on commit fa2393d

Please sign in to comment.