Issue 115222
Summary pack indexing addition to clang makes some valid C++11 code no longer compile in C++11-23 modes
Labels clang
Assignees
Reporter pinskia
    The example from https://eel.is/c++draft/diff#cpp23.dcl.dcl-2 which describes a different between C++23 and C++26:
```
template <typename... T>
void f(T... [1]);
template <typename... T>
void g(T... ptr[1]);
int main() {
  f<int, double>(nullptr, nullptr);     // ill-formed in C++26, but for c++11-23 would be void f<int, double>(int [1], double [1])
 g<int, double>(nullptr, nullptr);     // ok
}
```
No longer compiles in clang 19 with -std=c++11 due to the addition of pack indexing.

_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to