<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/128522>128522</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [clang-tidy] compile_commands.json parsing error resulting in file not found [clang-diagnostic-error]
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            clang-tidy
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          MrZaus
      </td>
    </tr>
</table>

<pre>
    When command field in compile_commands.json begins with /usr/share/arm-gnu-toolchain-12.3.rel1-x86_64-arm-none-eabi/bin/arm-none-eabi-g++ include flags are not parsed as expected resulting in errors 'file not found [clang-diagnostic-error]'.
I suspect JSONCompilationDatabase.cpp unwrapCommand.
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyUksuOnDwQhZ_GbCwQFNA0CxbT00L6fynJIotI2YwKuxo8MjZy2XN5-wimlcsii6wsleuU6nynkNnMjmgQ7UW01wxTXHwYPoXvmDibvH4fvi3kpPLrik7LmyGrpTkKm7H0dP_g4pm9kxPNxrF8NXGRAsbEQcDICwYSMGJY89mlPHpv1YLG5RUUdRHIVvnb-fR0avK9xXlHOeFkBIyTcXfhz2o-C7gIuEjjlE2a5M3izBIDSeej3DAwaYks6W0jFUnLQJxsNG7e96YQfGApoLsZ-yG5-eS0FO1FWXRzrg3OznM0Kj-aRXsV0BWifPhPcuJ9qPz_65fPjwcBjMa7K0ackKlQ2yaTew24PX5wKTI91Lqve8xoqLqmbKqy6vtsGXSJTdNPShFA15w1tXVHNLXYnBpqujYzA5TQlgBN1Van-lzg7VyruoO-L3utNYimpBWNLax9WQsf5swwJxoqOLcAmcWJLB_BAnxYi0a_C4A96DDsqnxKM4umtIYj_5oTTbTHSfwma69_yXwnvsM9YP0J-x8QZynYYYlxY1E_CBgFjLOJS5oK5VcB477b_cm34J9JRQHjYZgFjHfPLwP8CAAA__-W-_J6">