[clang] [clang-tools-extra] [clangd] [AST] Handle uninitialized type constraints (PR #110496)
Younan Zhang via cfe-commits
cfe-commits at lists.llvm.org
Mon Sep 30 19:55:41 PDT 2024
zyn0217 wrote:
@falbrechtskirchinger
We need to resort to `-fallow-pch-with-compiler-errors` :)
Specifically, add the following file to `clang/test/PCH` (or somehow merge it into a pre-existing test, which I'd prefer)
Name it with a reasonable name e.g. `cxx2a-invalid-constraint-serialization.cpp`
```cpp
// RUN: %clang_cc1 -std=c++2a -emit-pch -fallow-pch-with-compiler-errors %s -o %t
// RUN: %clang_cc1 -std=c++2a -include-pch %t -verify %s
namespace GH99036 {
template <typename T>
concept C;
template <C U> void f();
} // namespace GH99036
```
You can see a crash without your patch.
https://github.com/llvm/llvm-project/pull/110496
More information about the cfe-commits
mailing list