<div>There is a compile error when compiling VC++'s math.h.</div>
<div> </div>
<div>Apparently, the GNU extentions are still enabled by default for Windows VC++ builds, in particular "_Complex".</div>
<div> </div>
<div>This conflicts with the parameter name in:</div>
<div> </div>
<div>_CRTIMP double  __cdecl _cabs(__in struct _complex _Complex);</div>
<div> </div>
<div>During my investigation, I tried turning off the GNU extensions when the Microsoft extensions are enabled, but this is problematic with a number of the tests, which use _Complex, and probably lots of other places.  This raised the question in my mind as to whether the GNU extensions should be enabled in this case, but I figure it's probably better that way, making the compiler more flexible.</div>

<div> </div>
<div>Therefore, one way to make this work would be to change the parser a bit to detect this case, and treat the _Complex token as an identifier in this case.  The error originates from line 410 of DeclSpec.cpp.<br clear="all">
</div>
<div>Would this be a reasonable solution?</div>
<div> </div>
<div>I haven't looked in to how to do this yet, but if you think it's a good idea, I'll attempt it.</div>
<div> </div>
<div>Actually, today there are two other errors in compiling this file, related to wchar_t being defined already.  One solution is to define _WCHAR_T_DEFINED for the Visual Studio targets, which will disable the conflicting definition in crtdefs.h, and possibly elsewhere.  The enclosed patch does this, which if you will approve it, I'll check it in.</div>

<div> </div>
<div>To make the tests less dependent on headers, I've also enclosed a mathtest.patch file for eliminating the math.h inclusion in the failed tests I've looked at so far.</div>
<div> </div>
<div>-John</div>
<div></div><br>-- <br>John Thompson<br><a href="mailto:John.Thompson.JTSoftware@gmail.com">John.Thompson.JTSoftware@gmail.com</a><br><br>