The following piece of code produces a file with a single byte when compiled in MSVC, but when compiled by GCC 8.3 it produces an empty file.
std::wofstream out(&