Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix !INTERPOLATE; fully pass litvar.t.
  • Loading branch information
jnthn committed Jun 22, 2013
1 parent 2aa4972 commit 7f05613
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/core/Cursor.pm
Expand Up @@ -144,10 +144,11 @@ my class Cursor does NQPCursorRole {
}
else {
# The pattern is a string.
$len := nqp::chars( $topic );
my str $topic_str = $topic.Str;
$len := nqp::chars( $topic_str );
$match := $len < 1
|| ($i ?? nqp::lc(nqp::substr($tgt, $pos, $len)) eq nqp::lc($topic)
!! nqp::substr($tgt, $pos, $len) eq $topic);
|| ($i ?? nqp::lc(nqp::substr($tgt, $pos, $len)) eq nqp::lc($topic_str)
!! nqp::substr($tgt, $pos, $len) eq $topic_str);
}

if $match && $len > $maxlen && $pos + $len <= $eos {
Expand Down

0 comments on commit 7f05613

Please sign in to comment.