You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

11 lines
224 B

module Lox
class Error < StandardError
def initialize(line, where="", message)
error = "Error"
error << " #{where}" unless where.empty?
super("[line #{line}] #{error}: #{message}")
end
end
end