summaryrefslogtreecommitdiff
path: root/spec/ruby/command_line
diff options
context:
space:
mode:
authorKazuki Tsujimoto <kazuki@callcc.net>2020-12-13 11:47:02 +0900
committerKazuki Tsujimoto <kazuki@callcc.net>2020-12-13 11:51:49 +0900
commita8cf526ae99c9e0823cd8c7c5ac96e43061fafa6 (patch)
treea451fed4d2b21b9ffb4464226c815f578feff7a3 /spec/ruby/command_line
parent1b45174aeaad4ab0e14b37f70d60a1d43ae21adc (diff)
Don't emit warning when the pattern of one-line pattern matching is just a variable pattern
https://github.com/ruby/dev-meeting-log/blob/master/DevelopersMeeting20201210Japan.md#feature-17371-reintroduce-expr-in-pat-ktsj
Diffstat (limited to 'spec/ruby/command_line')
-rw-r--r--spec/ruby/command_line/dash_upper_w_spec.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/ruby/command_line/dash_upper_w_spec.rb b/spec/ruby/command_line/dash_upper_w_spec.rb
index 62c617b892c..b7056386069 100644
--- a/spec/ruby/command_line/dash_upper_w_spec.rb
+++ b/spec/ruby/command_line/dash_upper_w_spec.rb
@@ -33,11 +33,11 @@ ruby_version_is "2.7" do
describe "The -W command line option with :no-experimental" do
before do
ruby_version_is ""..."3.0" do
- @src = 'case 0; in a; end'
+ @src = 'case [0, 1]; in [a, b]; end'
end
ruby_version_is "3.0" do
- @src = '1 => a'
+ @src = '[0, 1] => [a, b]'
end
end