Skip to content

Commit

Permalink
strip undefines from Match.caps we cannot sort by .from
Browse files Browse the repository at this point in the history
This fixes a blowup for: say "foo" ~~ m/ $42=\w /
  • Loading branch information
FROGGS committed May 6, 2015
1 parent d7dbe15 commit 3434745
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/Match.pm
Expand Up @@ -41,7 +41,7 @@ my class Match is Capture is Cool {
if nqp::istype($p.value,Array) {
@caps.push: $p.key => $_ for $p.value.list
} else {
@caps.push: $p;
@caps.push: $p if $p.value.DEFINITE
}
}
@caps.sort: -> $p { $p.value.from }
Expand Down

0 comments on commit 3434745

Please sign in to comment.