Sha256: cd7cd48e1e9174402e538735996a08239c0e9243ca7574d24af02521e96ed305

Contents?: true

Size: 715 Bytes

Versions: 16

Compression:

Stored size: 715 Bytes

Contents

# encoding: utf-8

module Unparser
  class Emitter
    class Literal
      # Emitter for execute strings (xstr) nodes
      class ExecuteString < self

        OPEN = CLOSE = '`'.freeze

        handle :xstr

      private

        # Perform dispatch
        #
        # @return [undefined]
        #
        # @api private
        #
        def dispatch
          visit_parentheses(dynamic_body, OPEN, CLOSE)
        end

        # Return dynamic body
        #
        # @return [Parser::AST::Node]
        #
        # @api private
        #
        def dynamic_body
          Parser::AST::Node.new(:dyn_xstr_body, children)
        end

      end # ExecuteString
    end # Literal
  end # Emitter
end # Unparser

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
unparser-0.2.4 lib/unparser/emitter/literal/execute_string.rb
unparser-0.2.3 lib/unparser/emitter/literal/execute_string.rb
unparser-0.2.2 lib/unparser/emitter/literal/execute_string.rb
unparser-0.2.1 lib/unparser/emitter/literal/execute_string.rb
unparser-0.2.0 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.16 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.15 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.14 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.13 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.12 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.11 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.10 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.9 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.8 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.7 lib/unparser/emitter/literal/execute_string.rb
unparser-0.1.6 lib/unparser/emitter/literal/execute_string.rb