Class: SyntaxTree::TStringBeg
- Inherits:
-
Object
- Object
- SyntaxTree::TStringBeg
- Defined in:
- lib/syntax_tree.rb
Overview
TStringBeg represents the beginning of a string literal.
"string"
In the example above, TStringBeg represents the first set of quotes. Strings can also use single quotes. They can also be declared using the %q and %Q syntax, as in:
%q{string}
Instance Attribute Summary collapse
-
#location ⇒ Object
readonly
- Location
-
the location of this node.
-
#value ⇒ Object
readonly
- String
-
the beginning of the string.
Instance Method Summary collapse
-
#initialize(value:, location:) ⇒ TStringBeg
constructor
A new instance of TStringBeg.
Constructor Details
#initialize(value:, location:) ⇒ TStringBeg
Returns a new instance of TStringBeg.
11372 11373 11374 11375 |
# File 'lib/syntax_tree.rb', line 11372 def initialize(value:, location:) @value = value @location = location end |
Instance Attribute Details
#location ⇒ Object (readonly)
- Location
-
the location of this node
11370 11371 11372 |
# File 'lib/syntax_tree.rb', line 11370 def location @location end |
#value ⇒ Object (readonly)
- String
-
the beginning of the string
11367 11368 11369 |
# File 'lib/syntax_tree.rb', line 11367 def value @value end |