Open 41fa9ab2-4e9a-46d3-8102-9366090d3552 opened 3 years ago
I am hitting this too (17.0.1), after #62405.
This is making analyzing Unreal Engine (for example) source code even more difficult, and I will need to resort to ugly hacks to work around this. Maybe @PiotrZSL can provide some information?
@llvm/issue-subscribers-c-20
Author: None (41fa9ab2-4e9a-46d3-8102-9366090d3552)
Extended Description
Using the latest commit as of writing (https://github.com/llvm/llvm-project/commit/3fa2d37eb3f8acddcfde749ca822f2cc7d900cbb), clang-tidy fails to process the following preprocessed source:
The following command line was used:
In Release, clang-tidy outputs this error:
In Debug, clang-tidy crashes with this assert:
This only occurs with -std=c++20. It does not occur with -std=c++17.
If I disable the use of
ExpandModularHeadersPPCallbacks
here (https://github.com/llvm/llvm-project/blob/3fa2d37eb3f8acddcfde749ca822f2cc7d900cbb/clang-tools-extra/clang-tidy/ClangTidy.cpp#L414-L419) then clang-tidy succeeds even in C++20 mode.