Sha256: 2691e1a71228ae482a65e38e5a5827e6a54dc19b1804edf3a7d390e86d2fc389
Contents?: true
Size: 550 Bytes
Versions: 1
Compression:
Stored size: 550 Bytes
Contents
# frozen-string-literal: true module Leftovers module ValueProcessors class EachForDefinitionSet def initialize(then_processors) @then_processors = then_processors freeze end def process(str, node, method_node) definitions = Leftovers.map_or_self(@then_processors) do |then_processor| then_processor.process(str, node, method_node) end return definitions unless definitions.is_a?(Array) ::Leftovers::DefinitionNodeSet.new(definitions) end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
leftovers-0.8.0 | lib/leftovers/value_processors/each_for_definition_set.rb |