https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108503
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Ever confirmed|0 |1 Target Milestone|--- |13.0 Last reconfirmed| |2023-01-24 Status|UNCONFIRMED |NEW --- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Confirmed, here is a testcase that does not error out before the ICE: ``` namespace std { template<typename T> struct tuple_size; template<int, typename> struct tuple_element; } struct A { template <int I> int get() { return 1; } }; template<> struct std::tuple_size<A> { static const int value = 3; }; template<int I> struct std::tuple_element<I,A> { using type = int; }; struct B { A *begin(); A *end(); }; void f (B a) { #pragma omp for collapse(2) for (auto [i, j, k] : a) for (int l = i; l < j; l += k) ; } ``` Note -fopenmp -Wall is needed to get the ICE.