On Fri, Oct 19, 2012 at 2:00 AM, Roger Pack <rogerdpa...@gmail.com> wrote: >> Something is messing with the defines in your code, it works fine when I >> tested. >> >> $ x86_64-w64-mingw32-gcc -E >> mingw-w64/trunk/mingw-w64-headers/crt/intrin.h | grep wcslen >> size_t __attribute__((__cdecl__)) wcslen(const wchar_t *); >> >> $ x86_64-w64-mingw32-gcc -E >> mingw-w64/trunk/mingw-w64-headers/crt/wchar.h | grep wcslen >> size_t __attribute__((__cdecl__)) wcslen(const wchar_t *_Str); > > It appears that there is a > #define const > before a > #include <windows.h>
I get wcslen always with const params: $ x86_64-w64-mingw32-gcc -E cross_win64/x86_64-w64-mingw32/include/winnt.h | grep wcslen size_t __attribute__((__cdecl__)) wcslen(const wchar_t *_Str); size_t __attribute__((__cdecl__)) wcslen(const wchar_t *); $ i686-w64-mingw32-gcc -E cross_win32/i686-w64-mingw32/include/winnt.h | grep wcslen size_t __attribute__((__cdecl__)) wcslen(const wchar_t *_Str); $ i686-w64-mingw32-gcc -E cross_win32/i686-w64-mingw32/include/intrin.h | grep wcslen size_t __attribute__((__cdecl__)) wcslen(const wchar_t *); $ i686-w64-mingw32-gcc -E cross_win32/i686-w64-mingw32/include/wchar.h | grep wcslen size_t __attribute__((__cdecl__)) wcslen(const wchar_t *_Str); Who is defining const as an empty macro? That doesn't seem right. > > in this case. > > Now why would this fail in x86 but not in w32? > > Appears that in winnt.h, there is a #include <intrin.h> > that is hit in x86 mode but not w32 mode. > > appears around line 1102'ish is a > #if defined(__x86_64) > > that is making the difference. > Is this expected? > Thanks! > -roger- -- O.S. ------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_sfd2d_oct _______________________________________________ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public