Class: RBS::AST::Ruby::Annotations::Base
- Inherits:
-
Object
- Object
- RBS::AST::Ruby::Annotations::Base
- Defined in:
- lib/rbs/ast/ruby/annotations.rb,
sig/ast/ruby/annotations.rbs
Direct Known Subclasses
AliasAnnotation, BlockParamTypeAnnotation, ColonMethodTypeAnnotation, DoubleSplatParamTypeAnnotation, InstanceVariableAnnotation, MethodTypesAnnotation, ModuleSelfAnnotation, NodeTypeAssertion, ParamTypeAnnotation, ReturnTypeAnnotation, SkipAnnotation, SplatParamTypeAnnotation, TypeApplicationAnnotation
Instance Attribute Summary collapse
-
#location ⇒ Location
readonly
Location that covers all of the annotation.
-
#prefix_location ⇒ Location
readonly
Location of
@rbs,@rbs!, or:prefix.
Instance Method Summary collapse
- #buffer ⇒ Buffer
-
#initialize(location, prefix_location) ⇒ Base
constructor
A new instance of Base.
-
#type_fingerprint ⇒ Object
Returns the type fingerprint for this annotation.
Constructor Details
#initialize(location, prefix_location) ⇒ Base
Returns a new instance of Base.
10 11 12 13 |
# File 'lib/rbs/ast/ruby/annotations.rb', line 10 def initialize(location, prefix_location) @location = location @prefix_location = prefix_location end |
Instance Attribute Details
#location ⇒ Location (readonly)
Location that covers all of the annotation
26 27 28 |
# File 'sig/ast/ruby/annotations.rbs', line 26 def location @location end |
#prefix_location ⇒ Location (readonly)
Location of @rbs, @rbs!, or : prefix
30 31 32 |
# File 'sig/ast/ruby/annotations.rbs', line 30 def prefix_location @prefix_location end |
Instance Method Details
#buffer ⇒ Buffer
15 16 17 |
# File 'lib/rbs/ast/ruby/annotations.rb', line 15 def buffer location.buffer end |
#type_fingerprint ⇒ Object
Returns the type fingerprint for this annotation
37 |
# File 'sig/ast/ruby/annotations.rbs', line 37
def type_fingerprint: () -> untyped
|