Add guard to ensure generic mutator only visits nodes
This commit is contained in:
parent
df3ec6c0bf
commit
93da846051
1 changed files with 1 additions and 1 deletions
|
@ -28,7 +28,7 @@ module Mutant
|
||||||
#
|
#
|
||||||
def dispatch
|
def dispatch
|
||||||
children.each_index do |index|
|
children.each_index do |index|
|
||||||
mutate_child(index) if children.at(index)
|
mutate_child(index) if children.at(index).kind_of?(Parser::AST::Node)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue