repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
PR tree-optimization/86415 - strlen() not folded for substrings within constant arrays
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
cpp1z
/
decomp43.C
blob
ab917b436e4b50e5ca75d830dd08aa841b6a9922
1
// PR c++/85194
2
// { dg-do compile { target c++11 } }
3
// { dg-options "" }
4
5
struct A { int i; };
6
7
A x[2];
8
9
void
10
foo ()
11
{
12
for (auto [i] = A () : x) // { dg-error "initializer in range-based 'for' loop" }
13
; // { dg-warning "structured bindings only available with" "" { target c++14_down } .-1 }
14
}