summaryrefslogtreecommitdiffstats
path: root/regex.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-09-30 00:21:14 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-09-30 00:21:14 +0000
commitf83ff724cad84bed1e887c2653d9f03563879719 (patch)
tree5b1d006f36a07e0200a12c26309b6659639ec997 /regex.c
parent9b8d9ed92b3d1ba145f12b01ed0f70fe94d06549 (diff)
downloadruby-f83ff724cad84bed1e887c2653d9f03563879719.tar.gz
ruby-f83ff724cad84bed1e887c2653d9f03563879719.tar.xz
ruby-f83ff724cad84bed1e887c2653d9f03563879719.zip
* eval.c (rb_eval): while/until should not capture break unless
they are destination of the break. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@4629 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'regex.c')
-rw-r--r--regex.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/regex.c b/regex.c
index fea8bf9f7..d684eca83 100644
--- a/regex.c
+++ b/regex.c
@@ -3196,7 +3196,7 @@ re_search(bufp, string, size, startpos, range, regs)
}
}
if (bufp->options & RE_OPTIMIZE_ANCHOR) {
- if (bufp->options&RE_OPTION_SINGLELINE) {
+ if (bufp->options&RE_OPTION_MULTILINE && range > 0) {
goto begbuf_match;
}
anchor = 1;