Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gradle error matching doesn't work with row:column format #12

Open
mikuslaw opened this issue Mar 28, 2016 · 4 comments
Open

Gradle error matching doesn't work with row:column format #12

mikuslaw opened this issue Mar 28, 2016 · 4 comments

Comments

@mikuslaw
Copy link

Gradle error about missing header is not parsed correctly (native C++ compilation). Example of error message (notice filename:row:col: message format):
/.../Src/ProcessImageDataProvider.cpp:3:24: fatal error: OsAssert.hpp: No such file or directory
compilation terminated.

@mikuslaw
Copy link
Author

With this error match I'm able to get atom to recognize errors in gradle c++ builds. The last match is what was already in build-gradle, but it doesn't work with hpp and cpp matches I created. Not sure in which cases that match is used.

const errorMatch = [
'(?<file>/[^:\\n]+\\.java):(?<line>\\d+):',
'(?<file>/[^:\\n]+\\.cpp):(?<line>\\d+):(?<col>\\d+):\\s+(?<message>.+)',
'(?<file>/[^:\\n]+\\.hpp):(?<line>\\d+):(?<col>\\d+):\\s+(?<message>.+)',
``//'(?::compile(?:Api)?(?:Scala|Java|Groovy))?(?.+):(?\d+):\s.+[;:]'`

@keplersj
Copy link
Member

Mind posting your whole log? I initially created the match with Java, Scala, and Groovy in mind.

@mikuslaw
Copy link
Author

Sure, thank you for taking a look. The build is gcc running in gradle (standard native build in gradle). Native builds are not that popular, but it's a great substitution to cmake.

The issue I have is when the include file is not available from hpp file. In that case there are at least two paths: for the top cpp, and for the existing hpp (that has missing hpp include).

con.txt

@MaxThlon
Copy link

MaxThlon commented Apr 5, 2019

For those searching for kotlin matchs patern it's:
'(?/[^:\\n]+\.kt):\s\((?\d+),\s(?\d+)\):\s+(?.+)'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants