2012-12-29 14:12:48 -05:00
|
|
|
module Mutant
|
|
|
|
class Mutator
|
|
|
|
class Node
|
|
|
|
# Mutantor for default arguments
|
|
|
|
class DefaultArguments < self
|
|
|
|
handle(Rubinius::AST::DefaultArguments)
|
|
|
|
|
|
|
|
private
|
|
|
|
|
|
|
|
# Emit mutations
|
|
|
|
#
|
|
|
|
# @return [undefined]
|
|
|
|
#
|
|
|
|
# @api private
|
|
|
|
#
|
|
|
|
def dispatch
|
|
|
|
emit_attribute_mutations(:arguments) do |argument|
|
|
|
|
argument.names = argument.arguments.map(&:name)
|
2013-01-09 14:43:06 -05:00
|
|
|
argument
|
2012-12-29 14:12:48 -05:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|