den-run-ai / msinttypes

Automatically exported from code.google.com/p/msinttypes
0 stars 0 forks source link

misprint in stdint.h causing vc6 compilation problem #11

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
In line 45 of file stdint.h we see:

// For Visual Studio 6 in C++ mode and for many Visual Studio versions when
// compiling for ARM we should wrap <wchar.h> include with 'extern "C++" {}'
// or compiler give many errors like this:
//   error C2733: second C linkage of overloaded function 'wmemchr' not allowed
#ifdef __cplusplus
extern "C" {

Well then, why 'extern "C"' and not 'extern "C++"' then?

An attempt to compile in fact produces exactly the errors mentioned above.
Could you fix it please, it should not be difficult :P

Original issue reported on code.google.com by khani...@gmail.com on 20 Jan 2011 at 11:51

GoogleCodeExporter commented 9 years ago
I got those errors while compiling as C++ in Visual Studio 6.
I fixed it by re-adding extern "C++" for _MSC_VER < 1300

Original comment by flaviojs2005 on 8 Sep 2011 at 12:30

Attachments: