Keith Marshall
keith****@users*****
Thu Jun 28 01:20:12 JST 2018
On 27/06/18 16:59, Eli Zaretskii wrote: >> #include <_mingw.h> >> > >> > #ifndef RTX >> > #define GNAT_UNICODE_SUPPORT >> > #define _UNICODE /* For C runtime */ >> > #define UNICODE /* For Win32 API */ >> > #endif > This is supposed to define UNICODE unless RTX is defined. Does that > mean RTX is defined in your case? Because if it doesn't, then UNICODE > should have become defined, and should have caused 'TCHAR *' and > LPCTSTR become the same, and should have also caused > GetFileAttributesEx resolve to GetFileAttributesExW, which does expect > wchar_t strings. That presupposes that UNICODE/_UNICODE have been defined in proper time; in OP's case, the code to map GetFileAttributesEx to it UNICODE vs. ANSI variant has already been specified to select GetFileAttributesExA, when he included <_mingw.h> *before* he defined UNICODE/_UNICODE. > Which ones of these didn't work, and why? The mapping was already defined, to GetFileAttributesExA, because he did not define UNICODE/_UNICODE in time ... that *must* come *before* #include <_mingw.h> -- Regards, Keith. Public key available from keys.gnupg.net Key fingerprint: C19E C018 1547 DE50 E1D4 8F53 C0AD 36C6 347E 5A3F -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 836 bytes Desc: OpenPGP digital signature Url : https://lists.osdn.me/mailman/archives/mingw-users/attachments/20180627/f62782c3/attachment.pgp