Thanks for approval . The issue you pointed out is exactly the same problem. I also first tempted to fix
platform/switch_amd64_unix.h which was a default inclusion for mingw64. It was mainly an issue of sizeof(long) differs between Windows and Unix. It turned out that the culprit was not the platform/switch_amd64_unix.h, but including it instead of platform/switch_x64_msvc.h was.
I have used/worked for/loved several Linux distros. Arch was one of them. But currently I am pushed to use Windows 7 at my current job. It is a nightmare. I want my Linux environment back and msys2 is a good alternative. So I started to port the tools.
RE: Fix wrong platform inclusion for mingw64