mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* parse.y (f_larglist): should not allow semicolon separated local
variable declarations if formal argument list is not surrounded by parentheses, mostly because semicolon outside of parentheses appears to terminate the expression. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19886 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
4a3f2a7bc5
commit
e8a71e64a1
2 changed files with 8 additions and 1 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
Wed Oct 22 14:59:30 2008 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||||
|
|
||||||
|
* parse.y (f_larglist): should not allow semicolon separated local
|
||||||
|
variable declarations if formal argument list is not surrounded
|
||||||
|
by parentheses, mostly because semicolon outside of parentheses
|
||||||
|
appears to terminate the expression.
|
||||||
|
|
||||||
Wed Oct 22 14:52:17 2008 Yukihiro Matsumoto <matz@ruby-lang.org>
|
Wed Oct 22 14:52:17 2008 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||||
|
|
||||||
* string.c (rb_external_str_new_with_enc): no implicit strlen call.
|
* string.c (rb_external_str_new_with_enc): no implicit strlen call.
|
||||||
|
|
2
parse.y
2
parse.y
|
@ -3453,7 +3453,7 @@ f_larglist : '(' f_args opt_bv_decl rparen
|
||||||
$$ = dispatch1(paren, $2);
|
$$ = dispatch1(paren, $2);
|
||||||
%*/
|
%*/
|
||||||
}
|
}
|
||||||
| f_args opt_bv_decl
|
| f_args
|
||||||
{
|
{
|
||||||
/*%%%*/
|
/*%%%*/
|
||||||
$$ = NEW_LAMBDA($1);
|
$$ = NEW_LAMBDA($1);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue