diff options
author | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-05-25 08:18:16 +0000 |
---|---|---|
committer | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-05-25 08:18:16 +0000 |
commit | 1059cf6e30d6ce7ad91acb94ed142c19cf05fe0a (patch) | |
tree | 963aa23a3082a1de9ab430f7e2cc77ec7f11f823 /test/ruby | |
parent | a51d961b3095f5474220e917130366bb528e29aa (diff) |
merge revision(s) 35644:
* parse.y (f_arglist): should reset lexical states after empty
argument list with no parenthesis as well as parenthesized list,
so that reserved name method definition work. [ruby-dev:45626]
[Bug #6403]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_3@35791 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby')
-rw-r--r-- | test/ruby/test_syntax.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/ruby/test_syntax.rb b/test/ruby/test_syntax.rb index dcfdb09d80..215785a051 100644 --- a/test/ruby/test_syntax.rb +++ b/test/ruby/test_syntax.rb @@ -57,6 +57,11 @@ class TestSyntax < Test::Unit::TestCase assert_valid_syntax("def self; :foo; end", __FILE__, bug6403) end + def test_reserved_method_no_args + bug6403 = '[ruby-dev:45626]' + assert_valid_syntax("def self; :foo; end", __FILE__, bug6403) + end + private def make_tmpsrc(f, src) |