wchart_t vs. windows.h

Oct 17, 2011 at 12:19 PM

Hi,

I'm trying vld and got the following error message while compiling (VS 2010):

2>c:\program files\visual leak detector\include\vld_def.h(44): error C2143: syntax error : missing ')' before '*'
2>c:\program files\visual leak detector\include\vld_def.h(44): error C2081: 'wchar_t' : name in formal parameter list illegal
2>c:\program files\visual leak detector\include\vld_def.h(44): error C2143: syntax error : missing '{' before '*'
2>c:\program files\visual leak detector\include\vld_def.h(44): error C2059: syntax error : 'type'
2>c:\program files\visual leak detector\include\vld_def.h(44): error C2059: syntax error : ')'
2>C:\Program Files\Visual Leak Detector\include\vld.h(269): error C2146: syntax error : missing ')' before identifier 'pfnNewHook'
2>C:\Program Files\Visual Leak Detector\include\vld.h(269): error C2081: 'VLD_REPORT_HOOK' : name in formal parameter list illegal
2>C:\Program Files\Visual Leak Detector\include\vld.h(269): error C2061: syntax error : identifier 'pfnNewHook'
2>C:\Program Files\Visual Leak Detector\include\vld.h(269): error C2059: syntax error : ';'
2>C:\Program Files\Visual Leak Detector\include\vld.h(269): error C2059: syntax error : ')'

Root cause is the missing definition of "wchar_t". Including windows.h fixes the problem.

Is this already known? Am I doing something wrong?

Greets,

 Paul

Coordinator
Nov 2, 2011 at 4:15 PM

windows.h already included in vld.h. We can't reproduce your problem.