Sha256: 15f726901720aa88ae463ac6c2a099ddc7d08016332377c7a6a23577cd7e6d78

Contents?: true

Size: 475 Bytes

Versions: 11

Compression:

Stored size: 475 Bytes

Contents

# frozen_string_literal: true

module Unparser
  class Emitter

    # Emitter for yield node
    class Yield < self
      include Terminated

      handle :yield

    private

      # Perform dispatch
      #
      # @return [undefined]
      #
      # @api private
      #
      def dispatch
        write(K_YIELD)
        return if children.empty?

        parentheses do
          delimited(children)
        end
      end

    end # Yield

  end # Emitter
end # Unparser

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
unparser-0.4.9 lib/unparser/emitter/yield.rb
unparser-0.4.8 lib/unparser/emitter/yield.rb
unparser-0.4.7 lib/unparser/emitter/yield.rb
unparser-0.4.6 lib/unparser/emitter/yield.rb
unparser-0.4.5 lib/unparser/emitter/yield.rb
unparser-0.4.4 lib/unparser/emitter/yield.rb
unparser-0.4.3 lib/unparser/emitter/yield.rb
unparser-0.4.2 lib/unparser/emitter/yield.rb
unparser-0.4.1 lib/unparser/emitter/yield.rb
unparser-0.4.0 lib/unparser/emitter/yield.rb
unparser-0.3.0 lib/unparser/emitter/yield.rb