[clang] [Clang][ItaniumMangle] Fix infinite recursion mangling a lambda in an enable_if condition (PR #234686)

Eugene Velesevich via cfe-commits cfe-commits at lists.llvm.org
Fri Oct 23 04:54:39 PDT 2026


TabbySqui wrote:

Hello again,
For this approach is afraid the whole AST should be checked. It seems a bit overwhelming.

I mean the complicated cases may still fail.
```c++
template<typename R >
constexpr int get(){
return sizeof(R);
}

template<int N = 0>
int thefunc (int g) __attribute__((enable_if(get<decltype([](){})>(), ""))) {
  return 0;
}

int main() {
    return thefunc(0);
}
```

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


More information about the cfe-commits mailing list