Sha256: 4ceba296b08b7830b83ddbab6c1cd37c8f72ea8b731febffe79524e0e9bcba4a
Contents?: true
Size: 982 Bytes
Versions: 29
Compression:
Stored size: 982 Bytes
Contents
# encoding: utf-8 module Mutant class Mutator class Node # Mutator for begin nodes class Begin < self handle(:begin) private # Emit mutants # # @return [undefined] # # @api private # def dispatch Util::Array.each(children, self) do |children| emit_child_subset(children) end children.each_with_index do |child, index| mutate_child(index) emit(child) end end # Emit child subset # # @param [Array<Parser::AST::Node>] nodes # # @return [undefined] # # @api private # def emit_child_subset(children) case children.length when 0 when 1 emit(children.first) else emit_self(*children) end end end # Block end # Node end # Mutator end # Mutant
Version data entries
29 entries across 29 versions & 1 rubygems