http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54320
--- Comment #12 from Jason Merrill <jason at gcc dot gnu.org> --- (In reply to vincenzo Innocente from comment #3) > int foo2(int N) { > int v[N]; > for ( auto a : v) > if (a) return a; > return 0; > } > > works, though was similar to std::begin(v) std::end(v) Similar, but not the same: "if _RangeT is an array type, begin-expr and end-expr are __range and __range + __bound, respectively, where __bound is the array bound."