aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-22 01:37:36 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-10-22 01:37:36 +0000
commit7eddcca6dfeded73286b35bd274535e3e1921979 (patch)
treec018735e538a5d60bbed0c3b1f67701096d542ef /test
parent391763ccf416bb2a1ab41d59bee291f52eb75675 (diff)
downloadruby-7eddcca6dfeded73286b35bd274535e3e1921979.tar.gz
parse.y: workaround for warnings
* parse.y (mark_lvar_used): enable workaround to suppress unused local variables. [ruby-core:82656] [Bug #13872] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60339 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/ruby/test_parse.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/ruby/test_parse.rb b/test/ruby/test_parse.rb
index 5b973a0901..8830dbec30 100644
--- a/test/ruby/test_parse.rb
+++ b/test/ruby/test_parse.rb
@@ -890,6 +890,7 @@ x = __ENCODING__
assert_warning(/#{a}/) {o.instance_eval("def foo; #{a}=1; nil; end")}
o = Object.new
assert_warning(/assigned but unused variable/) {o.instance_eval("def foo; tap {a=1; a()}; end")}
+ assert_warning('') {o.instance_eval("def bar; a=a=1; nil; end")}
end
def test_named_capture_conflict