mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* parse.y (yylex): disallow alpha-numeric and mbchar for
terminator of %string. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1785 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
da23c37a31
commit
093595801f
2 changed files with 9 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
|||
Tue Oct 16 00:07:06 2001 Nobuyoshi Nakada <nobu.nakada@nifty.ne.jp>
|
||||
|
||||
* parse.y (yylex): disallow alpha-numeric and mbchar for
|
||||
terminator of %string.
|
||||
|
||||
Wed Oct 10 03:11:47 2001 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||
|
||||
* file.c (rb_stat_clone): should copy internal data too.
|
||||
|
|
4
parse.y
4
parse.y
|
@ -3528,6 +3528,10 @@ yylex()
|
|||
}
|
||||
else {
|
||||
term = nextc();
|
||||
if (ISALNUM(term) || ismbchar(term)) {
|
||||
yyerror("unknown type of %string");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
if (c == -1 || term == -1) {
|
||||
rb_compile_error("unterminated quoted string meets end of file");
|
||||
|
|
Loading…
Reference in a new issue