[clang] [Clang] Handle ?: operator in fold expression (PR #164019)

via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 11 05:19:57 PST 2025


https://github.com/Sirraide commented:

I’m not convinced this is the right approach; what if we have e.g.
```
template <typename ... T>
void foo(T... Params) {
  ([&]{ Params ?: 1; }(), ...);
}
```
We still crash on this and I’m sure `commonExpr` would still be pack-dependent in this case, but we don’t want this to become invalid.

I wonder if we should just delete the assertion in `computeDependence(OpaqueValueExpr*)`.

https://github.com/llvm/llvm-project/pull/164019


More information about the cfe-commits mailing list