Sha256: b00bdefd95885566cf172bbee6ebedc91072f08d98dc77777ae54c5adb1f9cc5

Contents?: true

Size: 524 Bytes

Versions: 23

Compression:

Stored size: 524 Bytes

Contents

# frozen_string_literal: true

module Mutant
  class Mutator
    class Node
      module Regexp
        # Mutator for regexp capture groups, such as `/(foo)/`
        class CaptureGroup < Node
          handle(:regexp_capture_group)

          children :group

        private

          def dispatch
            return unless group

            emit(s(:regexp_passive_group, group))
            emit_group_mutations
          end
        end # EndOfLineAnchor
      end # Regexp
    end # Node
  end # Mutator
end # Mutant

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
mutant-0.10.26 lib/mutant/mutator/node/regexp/capture_group.rb
mutant-0.10.25 lib/mutant/mutator/node/regexp/capture_group.rb
mutant-0.10.24 lib/mutant/mutator/node/regexp/capture_group.rb