Class: RBS::Inline::AST::Annotations::Embedded

Inherits:
Base
  • Object
show all
Defined in:
lib/rbs/inline/ast/annotations.rb

Overview

‘# @rbs!` annotation

Instance Attribute Summary collapse

Attributes inherited from Base

#source, #tree

Instance Method Summary collapse

Constructor Details

#initialize(tree, source) ⇒ Embedded

Returns a new instance of Embedded.



590
591
592
593
594
595
# File 'lib/rbs/inline/ast/annotations.rb', line 590

def initialize(tree, source)
  @tree = tree
  @source = source

  @content = tree.nth_token!(1)[1]
end

Instance Attribute Details

#contentObject (readonly)

: String



587
588
589
# File 'lib/rbs/inline/ast/annotations.rb', line 587

def content
  @content
end