mirror of
https://github.com/HowardHinnant/date.git
synced 2024-12-25 23:40:53 +08:00
workaround for gcc bug 106757
see: https://github.com/HowardHinnant/date/issues/750
This commit is contained in:
parent
88a3b15126
commit
0e65940a7f
@ -6527,7 +6527,14 @@ read(std::basic_istream<CharT, Traits>& is, int a0, Args&& ...args)
|
||||
*e++ = static_cast<CharT>(CharT(u % 10) + CharT{'0'});
|
||||
u /= 10;
|
||||
} while (u > 0);
|
||||
#ifdef __GNUC__
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wstringop-overflow"
|
||||
#endif
|
||||
std::reverse(buf, e);
|
||||
#ifdef __GNUC__
|
||||
#pragma GCC diagnostic pop
|
||||
#endif
|
||||
for (auto p = buf; p != e && is.rdstate() == std::ios::goodbit; ++p)
|
||||
read(is, *p);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user