Sha256: 11e5538c6d1246106c656c97775d7b04dadd4cbefacc8938a18f4b17933746c9

Contents?: true

Size: 385 Bytes

Versions: 13

Compression:

Stored size: 385 Bytes

Contents

module Furnace
  module Code
    class SurroundedToken < NonterminalToken
      def text_before
        ""
      end

      def text_after
        ""
      end

      def to_text
        "#{text_before}#{children.map(&:to_text).join}#{text_after}"
      end

      def to_structure(options={})
        structurize "#{text_before} ... #{text_after}", options
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
furnace-0.3.0.beta1 lib/furnace/code/surrounded_token.rb
furnace-0.2.6 lib/furnace/code/surrounded_token.rb
furnace-0.2.5 lib/furnace/code/surrounded_token.rb
furnace-0.2.4 lib/furnace/code/surrounded_token.rb
furnace-0.2.3 lib/furnace/code/surrounded_token.rb
furnace-0.2.2 lib/furnace/code/surrounded_token.rb
furnace-0.2.1 lib/furnace/code/surrounded_token.rb
furnace-0.2.0 lib/furnace/code/surrounded_token.rb
furnace-0.1.2 lib/furnace/code/surrounded_token.rb
furnace-0.1.1 lib/furnace/code/surrounded_token.rb
furnace-0.1.0 lib/furnace/code/surrounded_token.rb
furnace-0.0.8 lib/furnace/code/surrounded_token.rb
furnace-0.0.7 lib/furnace/code/surrounded_token.rb