
1 Jun
2015
1 Jun
'15
3:15 p.m.
On Monday 01 June 2015 18:01:48 Peter Dimov wrote:
Andrey Semashev wrote:
If the compiler checks that C++ declarations of the similarly named extern "C" functions have the same argument types then this is a showstopper and I don't think we can do anything except to always include and use windows.h on that compiler.
Maybe we can, but I'm not sure if it's worth it.
// at global scope struct FILETIME; extern "C" __declspec(dllimport) void __stdcall GetSystemTimeAsFileTime(FILETIME*);
namespace winapi { struct FILETIME { ... };
inline void GetSystemTimeAsFileTime( FILETIME * p ) { ::GetSystemTimeAsFileTime( (::FILETIME*)p ); } }
Interesting idea, I haven't though about it.