p4raw-id: //depot/perl@14205
#define HOPMAYBEc(pos,off) ((char*)HOPMAYBE(pos,off))
#define HOPBACK(pos, off) ( \
- (UTF && PL_reg_match_utf8) \
+ (PL_reg_match_utf8) \
? reghopmaybe((U8*)pos, -off) \
: (pos - off >= PL_bostr) \
? (U8*)(pos - off) \
$| = 1;
-print "1..846\n";
+print "1..847\n";
BEGIN {
chdir 't' if -d 't';
$r2 =~ s/\x{100}//;
print $r1 eq $r2 ? "ok 846\n" : "not ok 846\n";
}
+
+{
+ print "# Unicode lookbehind\n";
+
+ print "A\x{100}B" =~ /(?<=A.)B/ ? "ok 847\n" : "not ok 847\n";
+ print "A\x{200}\x{300}B" =~ /(?<=A..)B/ ? "ok 848\n" : "not ok 848\n";
+}