class Rley::Parser::ErrorReason
Abstract class. An instance represents an explanation describing the likely cause of a parse error detected by Rley
.
Attributes
@!attribute [r] rank
@return [Integer] The rank number of the offending input token
Public Class Methods
Source
# File lib/rley/parser/error_reason.rb, line 15 def initialize(aRank) @rank = aRank end
Constructor @param aRank [Integer] The sequence number of the offending input token.
Public Instance Methods
Source
# File lib/rley/parser/error_reason.rb, line 25 def inspect "#{self.class.name}: #{message}" end
@return [String] Return this reason’s class name and message
Source
# File lib/rley/parser/error_reason.rb, line 20 def message return to_s end
@return [String] the result of invoking reason.to_s