* regcomp.c (optimize_node_left, set_optimize_info_from_tree): right

handling for look behind anchor.

* regexec.c (onig_search): ditto.
  [Backport #8076]

this patch is derived from Onigmo base tree.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_3@39983 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
usa 2013-03-28 09:57:47 +00:00
parent 8096159871
commit ee09f19fdb
3 changed files with 16 additions and 3 deletions

View file

@ -3560,7 +3560,9 @@ onig_search(regex_t* reg, const UChar* str, const UChar* end,
}
}
else if ((reg->anchor & ANCHOR_ANYCHAR_STAR_ML)) {
goto begin_position;
if (!(reg->anchor & ANCHOR_LOOK_BEHIND)) {
goto begin_position;
}
}
}
else if (str == end) { /* empty string */