notskm / vscode-clang-tidy

MIT License
48 stars 26 forks source link

Fails when using old versions of clang-tidy #4

Closed notskm closed 5 years ago

notskm commented 5 years ago

At some point, the output of clang-tidy --export-fixes=- changed. The extension breaks when it encounters the old output. I'm working on a fix for this.


Old output:

MainSourceFile:  /path/to/main.cpp
Diagnostics:
  - DiagnosticName:  clang-analyzer-deadcode.DeadStores
    Message: 'Value stored to ''num'' during its initialization is never read'
    FileOffset: 85
    FilePath: /path/to/main.cpp
    Replacements:

New output:

MainSourceFile:  '/path/to/main.cpp'
Diagnostics:
  - DiagnosticName:  clang-analyzer-deadcode.DeadStores
    DiagnosticMessage:
      Message:         'Value stored to ''num'' during its initialization is never read'
      FilePath:        '/path/to/main.cpp'
      FileOffset:      85
      Replacements:    []
    Notes:
      - Message:         'Value stored to ''num'' during its initialization is never read'
        FilePath:        '/path/to/main.cpp'
        FileOffset:      85
        Replacements:    []