Debian Codegraph @

gcc/testsuite/g++.dg/cpp2a/range-for18.C

raw
1 // PR c++/87152
2 // { dg-do compile }
3 // { dg-options "-std=c++2a" }
4
5 template<int> void foo()
6 {
7 int a[] = { 1, 1, 1 };
8 for (int i = 0; auto x : a);
9 int i;
10 }
11
12 void
13 bar ()
14 {
15 foo<0>();
16 }