https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66157

--- Comment #7 from Luca Stoppa <luca.stoppa at bbh dot com> ---
Well, even if my production code is 20 years old, the example I have attached
isn't. It is valid c++11/14 code. 

Would you call something like this "old c++ code"?

#include <algorithm>

int main()
{
  std::vector<int> v{1,2,3,4,5,6,7,8};
  int sum = 0;
  for (auto &x : v )
    sum += x;
  for (auto &x : v)
    sum *= 2;

  return 0;
}

I don't think so. 
Anyway, you should at least add a small note into the documentation that this
doesn't work anymore with the new standard.

Reply via email to