A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://ruby-syntax-tree.github.io/syntax_tree/SyntaxTree/EmbDoc.html below:

class SyntaxTree::EmbDoc - RDoc Documentation

  1. SyntaxTree::
  2. EmbDoc
class SyntaxTree::EmbDoc

EmbDoc represents a multi-line comment.

 Attributes 
String

the contents of the comment

Public Class Methods

Source

def initialize(value:, location:)
  @value = value
  @location = location

  @leading = false
  @trailing = false
end
Public Instance Methods

Source

def ===(other)
  other.is_a?(EmbDoc) && value === other.value
end

Source

def accept(visitor)
  visitor.visit_embdoc(self)
end

Source

def copy(value: nil, location: nil)
  EmbDoc.new(
    value: value || self.value,
    location: location || self.location
  )
end

Source

def deconstruct_keys(_keys)
  { value: value, location: location }
end

Source

def format(q)
  if (q.parent.is_a?(DefNode) && q.parent.endless?) ||
       q.parent.is_a?(Statements)
    q.trim
  else
    q.breakable_return
  end

  q.text(value)
end

Source

def leading!
  @leading = true
end

Source

def leading?
  @leading
end

Source

def trailing!
  @trailing = true
end

Source

def trailing?
  @trailing
end

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4