Name: Erlang parser failure
When the Erlang parser fails, it is possible to record the failure as a violation on the file.
This way, not only it is possible to track the number of files that do not parse but also to easily find out why they do not parse.
Should be disabled in default profile.
Provide Erlang rule engine based on SSLR
How can I do this?
I do not know what went wrong, but it does not work for me... Can you check it? I did exactly the same as what the JS plugin has, but the methods of the checker are not triggered. (ParsingErrorCheck.class)
This doesn't work because in some visitors you assume that file is always parsed. For example in PublicDocumentedApiCounter method visitFile will be called with null argument, when file can't be parsed, which leads to NPE.
Thanks Evgeny for your help, the problem is fixed.
To finally fix this I did two commits: https://github.com/SonarCommunity/sonar-erlang/commit/1a7ad64af59503368918afa61ace2464ed9c6317 and https://github.com/SonarCommunity/sonar-erlang/commit/4583cf474be2f8e18fdaba64dd6d7edf6954b6bf
Hope problem will not be reintroduced again.