Thinking about this a little more, how about adding the ability for scopes to be used instead. This way a build output syntax can define all the patterns. Things like bazel
, make
or any other build system the calls other compilers can include the error syntax of their respective languages.
foo/bar.baz:10:4: my error
^^^^^^^^^^^^^^^^^^^^^^^^^^ meta.build.error
^^^^^^^^^^^ build.file.name
^^ build.file.row
^ build.file.column
^^^^^^^^ build.error
This opens up the possibility of capturing multiline errors too.
We should also support something like lines_regex:
error: foo/bar.baz
^^^^^^^^^^^^^^^^^^ meta.build.error
^^^^^^^^^^^ build.file.name
line:12: not good
^^^^^^^^^^^^^^^^^ meta.build.error.line
^^ build.file.row
^^^^^^^^ build.error
line:52: it's broken
^^^^^^^^^^^^^^^^^ meta.build.error.line
^^ build.file.row
^^^^^^^^^^ build.error