Sha256: 9503f9aa97ee0627f20b9e0624854817015686f1a4682af6030dd9f7a5af4c3a

Contents?: true

Size: 426 Bytes

Versions: 6

Compression:

Stored size: 426 Bytes

Contents

# frozen_string_literal: true

module RuboCop
  module AST
    # A node extension for `str`, `dstr` and `xstr` nodes. This will be used
    # in place of a plain node when the builder constructs the AST, making
    # its methods available to all `str` nodes within RuboCop.
    class StrNode < Node
      include BasicLiteralNode

      def heredoc?
        loc.is_a?(Parser::Source::Map::Heredoc)
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
rubocop-0.59.2 lib/rubocop/ast/node/str_node.rb
rubocop-0.59.1 lib/rubocop/ast/node/str_node.rb
rubocop-0.59.0 lib/rubocop/ast/node/str_node.rb
rubocop-0.58.2 lib/rubocop/ast/node/str_node.rb
rubocop-0.58.1 lib/rubocop/ast/node/str_node.rb
rubocop-0.58.0 lib/rubocop/ast/node/str_node.rb