Fortran: Fix PR 47485.
[gcc.git] / gcc / testsuite / g++.dg / warn / Wstringop-overflow-8.C
blob7666fa388ac13d0bff4856f98c42db6315e3c551
1 // PR c++/103534
2 // { dg-additional-options "-O -Wall" }
3 // { dg-skip-if "requires hosted libstdc++ for string" { ! hostedlib } }
5 #include <string>
7 std::string foo(std::string x)
9   // This used to get a bogus -Wstringop-overflow warning.
10   return std::string("1234567890123456") + x;