Closed msmolens closed 5 years ago
Line numbers aren't correct for errors when the "LineLength" rule isn't specified in the configuration file. This happens because GetLineNumber() assumes that CheckLineLength() has been run.
KWstyle.xml:
KWstyle.xml
<?xml version="1.0" encoding="iso-8859-1"?> <Description> <SemicolonSpace>0</SemicolonSpace> </Description>
example.cpp:
example.cpp
#include <iostream> int main(int argc, char * argv[]) { int i = 3;; std::cerr << i << std::endl; return 0; }
Command line:
$ KWStyle -xml ./KWStyle.xml -v -gcc example.cpp example.cpp:0: error: Too many semicolons
The error is on line 5, not line 0.
Tested with Kitware/KWStyle@76bf8fac39539a8835acf9e9db60c3f9b592df90.
Line numbers aren't correct for errors when the "LineLength" rule isn't specified in the configuration file. This happens because GetLineNumber() assumes that CheckLineLength() has been run.
KWstyle.xml
:example.cpp
:Command line:
The error is on line 5, not line 0.
Tested with Kitware/KWStyle@76bf8fac39539a8835acf9e9db60c3f9b592df90.