On Tue Nov 12 05:52:23 2024 +0000, Piotr Caban wrote:
Please move all the tests and implementation to ucrtbase - according to my quick testing the change belongs there.
i do see a difference between wine and windows with fopen (and variants) in ucrtbase
but my current reduced sample... ```c++ // cl /std:c++17 /source-charset:utf-8 /EHsc /MD fiopen.cpp #include <filesystem> #include <fstream>
int main() { std::setlocale(LC_ALL, "de_DE.utf8"); auto utf = std::filesystem::u8path(u8"utf_äÏöß_.txt"); auto s1 = std::ofstream(utf.string()); return 0; } ``` ...calls only into _Fiopen, which currently calls into _wfsopen
_Fiopen behaves like _fsopen while _Fiopen_wchar behaves like _wfsopen on my windows 10. and wine's _wfsopen (and variant) matches my windows
so i'd need to fix ucrtbase and also rework _Fiopen to call into _fsopen
is that what you meant?