Exception: Parser::SyntaxError
- Inherits:
-
StandardError
- Object
- StandardError
- Parser::SyntaxError
- Defined in:
- lib/parser/syntax_error.rb
Overview
SyntaxError is raised whenever parser detects a syntax error, similar to the standard SyntaxError class.
Instance Attribute Summary (collapse)
-
- (Parser::Diagnostic) diagnostic
readonly
Instance Method Summary (collapse)
-
- (SyntaxError) initialize(diagnostic)
constructor
A new instance of SyntaxError.
Constructor Details
- (SyntaxError) initialize(diagnostic)
Returns a new instance of SyntaxError
14 15 16 17 |
# File 'lib/parser/syntax_error.rb', line 14 def initialize(diagnostic) @diagnostic = diagnostic super(diagnostic.) end |
Instance Attribute Details
- (Parser::Diagnostic) diagnostic (readonly)
11 12 13 14 15 16 17 18 |
# File 'lib/parser/syntax_error.rb', line 11 class SyntaxError < StandardError attr_reader :diagnostic def initialize(diagnostic) @diagnostic = diagnostic super(diagnostic.) end end |