Current section

Files

Jump to
surface lib surface compiler parse_error.ex
Raw

lib/surface/compiler/parse_error.ex

defmodule Surface.Compiler.ParseError do
defexception [:file, :line, :column, :message]
@impl true
def message(exception) do
location =
exception.file
|> Path.relative_to_cwd()
|> Exception.format_file_line_column(exception.line, exception.column)
"#{location} #{exception.message}"
end
end