Class: Violet::ParserError
Overview
Internal: Records errors emitted by the parser.
Instance Attribute Summary collapse
-
#token ⇒ Object
readonly
Public: Gets the malformed ‘Token` associated with this error.
Instance Method Summary collapse
-
#initialize(message, token) ⇒ ParserError
constructor
Public: Creates a new ‘ParserError`.
Constructor Details
#initialize(message, token) ⇒ ParserError
Public: Creates a new ‘ParserError`.
message - The error message. token - The malformed ‘Token`.
13 14 15 16 |
# File 'lib/violet/parser.rb', line 13 def initialize(, token) @token = token super end |
Instance Attribute Details
#token ⇒ Object (readonly)
Public: Gets the malformed ‘Token` associated with this error.
7 8 9 |
# File 'lib/violet/parser.rb', line 7 def token @token end |