class TexLogParser::FileLineError
Matches messages of this form:
./plain.tex:31: Undefined control sequence. l.31 ...t contains some \ref{warnings} and \errors for testing.
Public Class Methods
new()
click to toggle source
Creates a new instance.
Calls superclass method
LogParser::RegExpPattern::new
# File lib/tex_log_parser/patterns/file_line_error.rb, line 13 def initialize super(%r{^(/?(?:.*?/)*[^/]+):(\d+):}) end
Public Instance Methods
read(lines)
click to toggle source
(see LogParser::RegExpPattern#read
)
Calls superclass method
LogParser::RegExpPattern#read
# File lib/tex_log_parser/patterns/file_line_error.rb, line 18 def read(lines) # @type [Message] msg msg, consumed = super(lines) msg.source_file = @start_match[1] line = @start_match[2].to_i msg.source_lines = { from: line, to: line } msg.preformatted = true msg.level = :error msg.message.gsub!(@start, '') [msg, consumed] end