diff options
Diffstat (limited to 'gcc-4.8/gcc/testsuite/g++.dg/cpp0x/range-for23.C')
-rw-r--r-- | gcc-4.8/gcc/testsuite/g++.dg/cpp0x/range-for23.C | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/gcc-4.8/gcc/testsuite/g++.dg/cpp0x/range-for23.C b/gcc-4.8/gcc/testsuite/g++.dg/cpp0x/range-for23.C new file mode 100644 index 000000000..849682c02 --- /dev/null +++ b/gcc-4.8/gcc/testsuite/g++.dg/cpp0x/range-for23.C @@ -0,0 +1,8 @@ +// PR c++/56722 +// { dg-do compile { target c++11 } } + +int main() +{ + for (const auto& i, 21) // { dg-error "has no initializer|expected" } + i; +} |