Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to parser 3.3.0 #1414

Merged
merged 1 commit into from
Jan 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# v0.11.27 2023-12-01

* [#1414](https://github.com/mbj/mutant/pull/1414)

Update to parser-3.3.0 dependency.

# v0.11.26 2023-12-01

* [#1409](https://github.com/mbj/mutant/pull/1409)
Expand Down
28 changes: 13 additions & 15 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
PATH
remote: .
specs:
mutant (0.11.26)
mutant (0.11.27)
diff-lcs (~> 1.3)
parser (~> 3.2.2, >= 3.2.2.4)
parser (~> 3.3.0)
regexp_parser (~> 2.8.2)
sorbet-runtime (~> 0.5.0)
unparser (~> 0.6.9)
Expand All @@ -17,17 +17,16 @@ GEM
remote: https://rubygems.org/
specs:
ast (2.4.2)
base64 (0.1.1)
diff-lcs (1.5.0)
json (2.6.3)
json (2.7.1)
language_server-protocol (3.17.0.3)
parallel (1.23.0)
parser (3.2.2.4)
parallel (1.24.0)
parser (3.3.0.2)
ast (~> 2.4.1)
racc
racc (1.7.1)
racc (1.7.3)
rainbow (3.1.1)
regexp_parser (2.8.2)
regexp_parser (2.8.3)
rexml (3.2.6)
rspec (3.12.0)
rspec-core (~> 3.12.0)
Expand All @@ -45,24 +44,23 @@ GEM
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.12.0)
rspec-support (3.12.1)
rubocop (1.56.4)
base64 (~> 0.1.1)
rubocop (1.59.0)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
parallel (~> 1.10)
parser (>= 3.2.2.3)
parser (>= 3.2.2.4)
rainbow (>= 2.2.2, < 4.0)
regexp_parser (>= 1.8, < 3.0)
rexml (>= 3.2.5, < 4.0)
rubocop-ast (>= 1.28.1, < 2.0)
rubocop-ast (>= 1.30.0, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.29.0)
rubocop-ast (1.30.0)
parser (>= 3.2.1.0)
ruby-progressbar (1.13.0)
sorbet-runtime (0.5.11064)
sorbet-runtime (0.5.11180)
unicode-display_width (2.5.0)
unparser (0.6.9)
unparser (0.6.12)
diff-lcs (~> 1.3)
parser (>= 3.2.2.4)

Expand Down
1 change: 1 addition & 0 deletions lib/mutant/mutator/node/send.rb
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ def emit_naked_receiver
emit(receiver) if receiver && !left_op_assignment?
end

# rubocop:disable Style/HashEachMethods - its not a hash ;)
def mutate_arguments
emit_type(receiver, selector)
remaining_children_with_index.each do |_node, index|
Expand Down
2 changes: 1 addition & 1 deletion lib/mutant/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

module Mutant
# Current mutant version
VERSION = '0.11.26'
VERSION = '0.11.27'
end # Mutant
60 changes: 31 additions & 29 deletions meta/def.rb
Original file line number Diff line number Diff line change
Expand Up @@ -230,35 +230,37 @@
mutation 'def foo(**); {}; end'
end

Mutant::Meta::Example.add :hash do
source 'def foo(**); bar { { ** } }; end'

mutation 'def foo(**); bar { nil }; end'
mutation 'def foo(**); bar { raise }; end'
mutation 'def foo(**); bar { {} }; end'
mutation 'def foo(**); bar { }; end'
mutation 'def foo(**); bar; end'
mutation 'def foo(**); end'
mutation 'def foo(**); nil; end'
mutation 'def foo(**); raise; end'
mutation 'def foo(**); super; end'
mutation 'def foo(**); { ** }; end'
end

Mutant::Meta::Example.add :hash do
source 'def foo(*); bar { boz(*) }; end'

mutation 'def foo(*); bar { boz }; end'
mutation 'def foo(*); bar { nil }; end'
mutation 'def foo(*); bar { raise }; end'
mutation 'def foo(*); bar { }; end'
mutation 'def foo(*); bar.boz(*); end'
mutation 'def foo(*); bar; end'
mutation 'def foo(*); boz(*); end'
mutation 'def foo(*); end'
mutation 'def foo(*); nil; end'
mutation 'def foo(*); raise; end'
mutation 'def foo(*); super; end'
if RUBY_VERSION <= '3.3'
Mutant::Meta::Example.add :hash do
source 'def foo(**); bar { { ** } }; end'

mutation 'def foo(**); bar { nil }; end'
mutation 'def foo(**); bar { raise }; end'
mutation 'def foo(**); bar { {} }; end'
mutation 'def foo(**); bar { }; end'
mutation 'def foo(**); bar; end'
mutation 'def foo(**); end'
mutation 'def foo(**); nil; end'
mutation 'def foo(**); raise; end'
mutation 'def foo(**); super; end'
mutation 'def foo(**); { ** }; end'
end

Mutant::Meta::Example.add :hash do
source 'def foo(*); bar { boz(*) }; end'

mutation 'def foo(*); bar { boz }; end'
mutation 'def foo(*); bar { nil }; end'
mutation 'def foo(*); bar { raise }; end'
mutation 'def foo(*); bar { }; end'
mutation 'def foo(*); bar.boz(*); end'
mutation 'def foo(*); bar; end'
mutation 'def foo(*); boz(*); end'
mutation 'def foo(*); end'
mutation 'def foo(*); nil; end'
mutation 'def foo(*); raise; end'
mutation 'def foo(*); super; end'
end
end
end

Expand Down
2 changes: 1 addition & 1 deletion mutant.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Gem::Specification.new do |gem|
gem.required_ruby_version = '>= 3.0'

gem.add_runtime_dependency('diff-lcs', '~> 1.3')
gem.add_runtime_dependency('parser', '~> 3.2.2', '>= 3.2.2.4')
gem.add_runtime_dependency('parser', '~> 3.3.0')
gem.add_runtime_dependency('regexp_parser', '~> 2.8.2')
gem.add_runtime_dependency('sorbet-runtime', '~> 0.5.0')
gem.add_runtime_dependency('unparser', '~> 0.6.9')
Expand Down
10 changes: 5 additions & 5 deletions test_app/Gemfile.minitest.lock
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
PATH
remote: ..
specs:
mutant (0.11.26)
mutant (0.11.27)
diff-lcs (~> 1.3)
parser (~> 3.2.2, >= 3.2.2.4)
parser (~> 3.3.0)
regexp_parser (~> 2.8.2)
sorbet-runtime (~> 0.5.0)
unparser (~> 0.6.9)
mutant-minitest (0.11.26)
mutant-minitest (0.11.27)
minitest (~> 5.11)
mutant (= 0.11.26)
mutant (= 0.11.27)

GEM
remote: https://oss:Px2ENN7S91OmWaD5G7MIQJi1dmtmYrEh@gem.mutant.dev/
Expand All @@ -22,7 +22,7 @@ GEM
ast (2.4.2)
diff-lcs (1.5.0)
minitest (5.17.0)
parser (3.2.2.4)
parser (3.3.0.2)
ast (~> 2.4.1)
racc
racc (1.7.1)
Expand Down
10 changes: 5 additions & 5 deletions test_app/Gemfile.rspec3.8.lock
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
PATH
remote: ..
specs:
mutant (0.11.26)
mutant (0.11.27)
diff-lcs (~> 1.3)
parser (~> 3.2.2, >= 3.2.2.4)
parser (~> 3.3.0)
regexp_parser (~> 2.8.2)
sorbet-runtime (~> 0.5.0)
unparser (~> 0.6.9)
mutant-rspec (0.11.26)
mutant (= 0.11.26)
mutant-rspec (0.11.27)
mutant (= 0.11.27)
rspec-core (>= 3.8.0, < 4.0.0)

GEM
Expand All @@ -27,7 +27,7 @@ GEM
ice_nine (0.11.2)
memoizable (0.4.2)
thread_safe (~> 0.3, >= 0.3.1)
parser (3.2.2.4)
parser (3.3.0.2)
ast (~> 2.4.1)
racc
racc (1.7.1)
Expand Down