Begin
represents a begin..end chain.
begin value endAttributes
BodyStmt
the bodystmt that contains the contents of this begin block
def initialize(bodystmt:, location:) @bodystmt = bodystmt @location = location @comments = [] endPublic Instance Methods Source
def ===(other) other.is_a?(Begin) && bodystmt === other.bodystmt endSource
def accept(visitor) visitor.visit_begin(self) endSource
def child_nodes [bodystmt] endSource
def copy(bodystmt: nil, location: nil) node = Begin.new( bodystmt: bodystmt || self.bodystmt, location: location || self.location ) node.comments.concat(comments.map(&:copy)) node endSource
def deconstruct_keys(_keys) { bodystmt: bodystmt, location: location, comments: comments } endSource
def format(q) q.text("begin") unless bodystmt.empty? q.indent do q.breakable_force unless bodystmt.statements.empty? q.format(bodystmt) end end q.breakable_force q.text("end") 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