зеркало из https://github.com/github/ruby.git
* parse.y (parse_string): part of multi-byte sequence must not
match to paren. * parse.y (parse_qstring): ditto. * parse.y (parse_quotedwords): ditto. * parse.y (str_extend): handle multi-byte characters. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2218 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
e3235029ad
Коммит
22270b6d4b
11
ChangeLog
11
ChangeLog
|
@ -1,3 +1,14 @@
|
|||
Mon Mar 18 10:55:03 2002 Nobuyoshi Nakada <nobu.nakada@nifty.ne.jp>
|
||||
|
||||
* parse.y (parse_string): part of multi-byte sequence must not
|
||||
match to paren.
|
||||
|
||||
* parse.y (parse_qstring): ditto.
|
||||
|
||||
* parse.y (parse_quotedwords): ditto.
|
||||
|
||||
* parse.y (str_extend): handle multi-byte characters.
|
||||
|
||||
Mon Mar 18 10:31:20 2002 Nobuyoshi Nakada <nobu.nakada@nifty.ne.jp>
|
||||
|
||||
* enum.c (enum_find): catch a value before recycle.
|
||||
|
|
32
parse.y
32
parse.y
|
@ -2608,6 +2608,10 @@ parse_string(func, term, paren)
|
|||
rb_compile_error("unterminated string meets end of file");
|
||||
return 0;
|
||||
}
|
||||
if (paren) {
|
||||
if (c == paren) nest++;
|
||||
if (c == term && nest-- == 0) break;
|
||||
}
|
||||
if (ismbchar(c)) {
|
||||
int i, len = mbclen(c)-1;
|
||||
|
||||
|
@ -2635,10 +2639,6 @@ parse_string(func, term, paren)
|
|||
}
|
||||
continue;
|
||||
}
|
||||
if (paren) {
|
||||
if (c == paren) nest++;
|
||||
if (c == term && nest-- == 0) break;
|
||||
}
|
||||
tokadd(c);
|
||||
}
|
||||
|
||||
|
@ -2682,6 +2682,10 @@ parse_qstring(term, paren)
|
|||
rb_compile_error("unterminated string meets end of file");
|
||||
return 0;
|
||||
}
|
||||
if (paren) {
|
||||
if (c == paren) nest++;
|
||||
if (c == term && nest-- == 0) break;
|
||||
}
|
||||
if (ismbchar(c)) {
|
||||
int i, len = mbclen(c)-1;
|
||||
|
||||
|
@ -2709,10 +2713,6 @@ parse_qstring(term, paren)
|
|||
tokadd('\\');
|
||||
}
|
||||
}
|
||||
if (paren) {
|
||||
if (c == paren) nest++;
|
||||
if (c == term && nest-- == 0) break;
|
||||
}
|
||||
tokadd(c);
|
||||
}
|
||||
|
||||
|
@ -2743,6 +2743,10 @@ parse_quotedwords(term, paren)
|
|||
rb_compile_error("unterminated string meets end of file");
|
||||
return 0;
|
||||
}
|
||||
if (paren) {
|
||||
if (c == paren) nest++;
|
||||
if (c == term && nest-- == 0) break;
|
||||
}
|
||||
if (ismbchar(c)) {
|
||||
int i, len = mbclen(c)-1;
|
||||
|
||||
|
@ -2782,10 +2786,6 @@ parse_quotedwords(term, paren)
|
|||
pushback(c);
|
||||
continue;
|
||||
}
|
||||
if (paren) {
|
||||
if (c == paren) nest++;
|
||||
if (c == term && nest-- == 0) break;
|
||||
}
|
||||
tokadd(c);
|
||||
}
|
||||
|
||||
|
@ -4107,6 +4107,14 @@ str_extend(list, term, paren)
|
|||
newtok();
|
||||
return list;
|
||||
}
|
||||
else if (ismbchar(c)) {
|
||||
int i, len = mbclen(c)-1;
|
||||
|
||||
for (i = 0; i < len; i++) {
|
||||
tokadd(c);
|
||||
c = nextc();
|
||||
}
|
||||
}
|
||||
case '\n':
|
||||
tokadd(c);
|
||||
break;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
#define RUBY_VERSION "1.7.2"
|
||||
#define RUBY_RELEASE_DATE "2002-03-15"
|
||||
#define RUBY_RELEASE_DATE "2002-03-18"
|
||||
#define RUBY_VERSION_CODE 172
|
||||
#define RUBY_RELEASE_CODE 20020315
|
||||
#define RUBY_RELEASE_CODE 20020318
|
||||
|
|
Загрузка…
Ссылка в новой задаче