mutant 0.11.22 → 0.11.23
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mutant/mutator/node/arguments.rb +6 -2
- data/lib/mutant/mutator/node/block.rb +1 -1
- data/lib/mutant/mutator/node/send.rb +1 -1
- data/lib/mutant/version.rb +1 -1
- metadata +10 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fa07ddf4b4373385631a41ea909149b416a97eaeaa51c0f259d846fbf5488c24
|
4
|
+
data.tar.gz: ef900eed75c28e9ad08e21e2ed026dd4184808125ed5338c36e421659c388ff1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e5a6f9a778791413e93f0b9d427d3636e4cbfba89581f1b196a03fa2bd528935550405da4a02e281a72476fac6dbd8a5a11ad101e484989051de36305fea3a63
|
7
|
+
data.tar.gz: 256ba65540c021c9855248dfe4aeff4a230e2cd4119119b4e46ff5f82c1c1eac540d8a4e2f9b1345be9f2b81d171ecfbae5a11ae03d1139643522dd190c0e77c
|
@@ -25,18 +25,22 @@ module Mutant
|
|
25
25
|
children.each_with_index do |removed, index|
|
26
26
|
new_arguments = children.dup
|
27
27
|
new_arguments.delete_at(index)
|
28
|
-
unless
|
28
|
+
unless forward_type?(removed) || removed_block_arg?(new_arguments) || only_mlhs?(new_arguments)
|
29
29
|
emit_type(*new_arguments)
|
30
30
|
end
|
31
31
|
end
|
32
32
|
end
|
33
33
|
|
34
|
+
def forward_type?(removed)
|
35
|
+
n_forward_arg?(removed) || n_restarg?(removed) || n_kwrestarg?(removed)
|
36
|
+
end
|
37
|
+
|
34
38
|
def only_mlhs?(new_arguments)
|
35
39
|
new_arguments.one? && n_mlhs?(new_arguments.first)
|
36
40
|
end
|
37
41
|
|
38
42
|
def forward_arg?
|
39
|
-
children.
|
43
|
+
children.any?(&method(:forward_type?))
|
40
44
|
end
|
41
45
|
|
42
46
|
def removed_block_arg?(new_arguments)
|
@@ -223,7 +223,7 @@ module Mutant
|
|
223
223
|
|
224
224
|
argument = Mutant::Util.one(arguments)
|
225
225
|
|
226
|
-
return if n_kwargs?(argument) || n_forwarded_args?(argument)
|
226
|
+
return if n_kwargs?(argument) || n_forwarded_args?(argument) || n_forwarded_restarg?(argument)
|
227
227
|
|
228
228
|
emit_propagation(argument)
|
229
229
|
end
|
data/lib/mutant/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mutant
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.11.
|
4
|
+
version: 0.11.23
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Markus Schirp
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-10-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: diff-lcs
|
@@ -31,6 +31,9 @@ dependencies:
|
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: 3.2.2
|
34
|
+
- - ">="
|
35
|
+
- !ruby/object:Gem::Version
|
36
|
+
version: 3.2.2.4
|
34
37
|
type: :runtime
|
35
38
|
prerelease: false
|
36
39
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -38,6 +41,9 @@ dependencies:
|
|
38
41
|
- - "~>"
|
39
42
|
- !ruby/object:Gem::Version
|
40
43
|
version: 3.2.2
|
44
|
+
- - ">="
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: 3.2.2.4
|
41
47
|
- !ruby/object:Gem::Dependency
|
42
48
|
name: regexp_parser
|
43
49
|
requirement: !ruby/object:Gem::Requirement
|
@@ -72,14 +78,14 @@ dependencies:
|
|
72
78
|
requirements:
|
73
79
|
- - "~>"
|
74
80
|
- !ruby/object:Gem::Version
|
75
|
-
version: 0.6.
|
81
|
+
version: 0.6.9
|
76
82
|
type: :runtime
|
77
83
|
prerelease: false
|
78
84
|
version_requirements: !ruby/object:Gem::Requirement
|
79
85
|
requirements:
|
80
86
|
- - "~>"
|
81
87
|
- !ruby/object:Gem::Version
|
82
|
-
version: 0.6.
|
88
|
+
version: 0.6.9
|
83
89
|
- !ruby/object:Gem::Dependency
|
84
90
|
name: parallel
|
85
91
|
requirement: !ruby/object:Gem::Requirement
|