none
winnt.h(222): Error C2146 ...

    Question

  • All,

    line 222 in winnt.h reads like this:

         typedef
    void * POINTER_64 PVOID64;

    and creates the error message

         Error C2146: syntax error: missing ';' before identifier PVOID64.

    I am trying to throw VC++ 2005 Express on Windows 2000 Pro SP4 at a modifed version of the amcap sample program of DirectShow.  This is the version I have downloaded with DirectX 9.0b on 11 Oct. 2004 and have successfully used with VC++ 6 SP5 on the same program.  (The DXSDK involved is (one of) the last issue of DirectX that included DirectShow.)

    I have the platform SDK downloaded, and putting its include directory before or after the baseclasses and DXSDK include directories does not change anything.

    To me, the line in question looks wrong at first sight, and I agree with the compiler that PVOID64 is an extraneous element there.  However, I am not sure if by some "hidden" #define the POINTER_64 takes on a meaning that would make "void * POINTER_64" a legitimate multi-worded data type.  I have not installed any 64-bit pieces because at this time, 64-bit computing is irrelevant for me.

    There are a few other messages, which may or may not help in diagnosing the one at hand.  First is one about line 278 "operator=(LONG);" in baseclasses\ctlutil.h missing a type specifier, and the second one is about "atlbase.h" missing (I suspect another piece of download needed, or I have kept the installation of the platform SDK too tight).

    I have previously recompiled and modified another, simpler program that uses only the platform SDK but not any Direct-whatnot stuff under VC++ 2005 Express successfully.

    Question:

    Is the compiler correct in annotating a bug in winnt.h, i.e., the Platform SDK, or did I miss or mess up something in carrying my amcap derivate over from VC++ 6?

    I appreciate any and all comments and suggestions.

    Cheers,         Jochen

    Wednesday, July 27, 2005 8:27 PM

Answers

  • No: the problem here is that this member operator function does not have a return type:

        operator=(LONG);

    By looking at the code it seems that it should be:

        COARefTime& operator=(LONG);
    Thursday, July 28, 2005 4:45 PM
    Moderator

All replies

  • Okay, okay, I goofed - on three counts.

    >>I am trying to throw VC++ 2005 Express on Windows 2000 Pro SP4 at a modifed version of the amcap sample program of DirectShow.  This is the version I have downloaded with DirectX 9.0b on 11 Oct. 2004 ...<<

    The Platform SDK contains DirectShow and I have kept it during installation, so I suppose that is what I am using.

    >>I have the platform SDK downloaded, and putting its include directory before or after the baseclasses and DXSDK include directories does not change anything.<<

    Wrong.  Putting the Platform SDK include directory first gets rid of the C2146 error.  Interesting is that the mouse-over display says "typedef void *POINTER_64" when I am over POINTER_64 and "typedef void *PVOID64" when I am over PVOID64 ...

    The third goof is missing the Platform SDK's subdirectory "Include\atl".  (VC++ 6 either has the corresponding ATL\Include directory apparently automatically used.)

    That leaves me with just one error to figure out,

       line 278 "operator=(LONG);" in baseclasses\ctlutil.h missing a type specifier (error C4430)

    I have made sure that the baseclasses of the directShow piece in the Platform SDK is used.

    I apoogize for the premature alarms.

    Cheers,             Jochen

    Wednesday, July 27, 2005 9:36 PM
  • Hi Hans-Jochen,

    seems to me that ctlutil.h is missing an include so that LONG is not defined at that point.
    Make sure to include winnt.h or windows.h before using LONG in ctlutil.h.

    HTH,
    SvenC
    Thursday, July 28, 2005 6:19 AM
  • No: the problem here is that this member operator function does not have a return type:

        operator=(LONG);

    By looking at the code it seems that it should be:

        COARefTime& operator=(LONG);
    Thursday, July 28, 2005 4:45 PM
    Moderator
  • Jonathan,

    thanks for your advice.  Yes, it makes the compilation error C4430 in ctlutil.h go away.  This is 100% Microsoft's code, not mine, so I will post a bug report.  Your heroic efforts at implementing faithfully the C++ standard have struck here - VC++ 6 SP5 does not complain about this code (taken from DXSDK 9.0b where this passage is identical).

    Cheers,             Jochen
    Thursday, July 28, 2005 5:07 PM
  • I have a similar error

    1>C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(222) : error C2146: syntax error : missing ';' before identifier 'PVOID64'

    1>C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(222) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

    1>C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(5940) : error C2146: syntax error : missing ';' before identifier 'Buffer'

    1>C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(5940) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

    1>C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(5940) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

    ...which are all in winnt.h, which is included from windows.h (as far as I can tell - is there a problem with the "show Includes" option). Is there an updated set of h files I need to download?

    Cheers
    John
    • Proposed as answer by Derric Lyns Thursday, December 30, 2010 8:02 PM
    Friday, November 11, 2005 5:28 PM
  • This does indeed look like the same issue. I would first use the /showIncludes compiler option to ensure that you have a consistent set of include files. If that doesn't show up any problems then I would ensure that the version of the Platform SDK that you are using matches the version of Visual C++ 2005 that you have installed.
    Friday, November 11, 2005 5:52 PM
    Moderator
  • I had a similar error. One which I just fixed, but thought I should post the solution.  In case someone else runs accross this same issue, I could potentially save you some work.

    Basically what happened was that I thought that the issue was with the Visual Studio Include files order (see Tools->Options->Projects and Solutions->VC++ Directories->Show directories for: Include files). Only a while later did I realize that the problem was that the project itself had some include files (see project Properties->Configuration Properties->C/C++->General) that takes precedence over the Visual Studio Include files.  I also included the directshow header files in the VS Include files, but this time, since they were explicitly listed there, I could choose which order I wanted them in, i.e. that the Platform SDK had higher priority than the DirectX directories.

    Other than that I had to patch a few bugs with the BaseClasses source files. One was the "operator=(LONG);" issue already discussed elsewhere in this thread.  In a few places there were "int"s declared in for loops that had to be declared outside the for loops.

     - Waldemar

    Saturday, December 03, 2005 10:15 PM
  • There are several bugs in the BaseClasses when you compile it with vs2005, but they are easy to fix. There are two for scoping errors, the static variable definition error and that one for the operator= which was pointed out. Thats what I can remember.
    But one thing for you to try. When I was compiling an application the other day, it was complaining that something was undefined, but it should have been. I managed to trace this back to _WIN32_WINNT not being defined. So double check that you do have this defined. Also, make sure that any other preprocessor directives that you need are also defined.
    Sunday, December 04, 2005 2:18 PM
  • Hi,
        I fixed the problems mentioned above. The only problem now is the compiler can't find <fstream.h>. I tried just including <fstream> but it didn't recognise the functions (this also happens in VC++ 6.0).
         Any ideas would be helpful.

    All the best.
    Sunday, December 04, 2005 6:00 PM
  • ah, fixed the problem.. if i include <fstream> I have to declare std namespace before using the code. Thanks for the help with the original compiling problems.

    Cya!
    Sunday, December 04, 2005 6:14 PM
  • I have an orrorific solution for problem C2146.

    I found into file baseTsd.h the definition for POINTER_64 which is this,

    at line 22 more less:


    #ifndef _BASETSD_H_

    #define _BASETSD_H_

    #if !defined(_MAC) && (defined(_M_MRX000) || defined(_M_AMD64) || defined(_M_IA64)) && (_MSC_VER >= 1100) && !(defined(MIDL_PASS) || defined(RC_INVOKED))

    #define POINTER_64 __ptr64  // <-- This code is not called for some reason.

    typedef unsigned __int64



    I simply put this definition over the POINTER_64 typedef like this:

    #define POINTER_64 __ptr64  // <<---- ORROR !!!

    typedef void *PVOID;

    typedef void * POINTER_64 PVOID64;

    And I was able to compile my Torque Game Engine SDK with absolutelly no functionality problems.

    Tuesday, December 06, 2005 2:11 PM
  • Thanks a lot everyone. This discussion helped me alot to get started with VS2005 and directshow.

    Thanks,
    krishna.
    Thursday, January 26, 2006 8:39 AM
  • I am experiencing this issue as well...is there an "official" solution?
    Tuesday, January 31, 2006 3:45 PM
  • I may have a solution that doesn't involve modifying the base files.  In "Tools -> Options -> Projects and Solutions -> VC++ Directories -> Include Files" make sure the default include folders are first, and put any extra include folders you want here.

    In the project properties under "C/C++ -> General" make sure the "Additional Include Directories" is empty.  Any additional include directories should be in the folder above. 

    This solved all my problems.  Hope it solves yours!

    Saturday, April 15, 2006 2:38 PM
  • I tried to move all the library load orders and still had the issue. After putting the library load orders back the way they were (as per the Torque guide on how to upgrade RTS v1.3 to v1.4 http://tdn.garagegames.com/wiki/RTS/Compiling) I opened the Winnt.h file and added the following line:

    #define POINTER_64 __ptr64

    at line number 220 just above these lines:

    typedef void *PVOID;
    typedef void * POINTER_64 PVOID64;

    Torque RTS v1.3 upgrade to v1.4 then compiled without any errors. I noticed that there is some code at line 217 that appears to have been voided and thought maybe the coder delete the definition? As I am not a C++ guy, I hope this was correct and helps others. I will not this change to the Torque docs.

    Brian Peal

    Monday, July 03, 2006 2:18 AM
  • In liu of editing the headers, is there a compiler flag that would allow the compiler to be more forgiving and backward compatible in regards to acceptable syntax so that we don't "have" to edit this type of declaration in header files? 

    I understand the reason for this change and I think it's a good change, but a flag to fallback to old syntax rules would be nice for those cases where we want to build and use pre-existing code without having to change it. 

     

    Wednesday, August 16, 2006 9:08 PM
  • I've had this problem too, and have found that the solution is to remove the DXSDK include directory from the projects additional includes (in the project settings). The projects additional includes are searched first - typically before the platform SDK, and my DXSDK has a basetsd.h in it, which is not compatible with the winnt.h in my platform sdk.

    Maybe this helps?
    Wednesday, August 23, 2006 10:45 AM
  • Hello, I´ve got the C2146-error and the "ctlutil.h-error too and fixed it with your help.

    But this creates new errors: (sorry it´s in german)

     

    1>.\winutil.cpp(2104) : error C2065: 'Count': nichtdeklarierter Bezeichner

    1>.\winutil.cpp(2106) : error C2228: Links von ".peRed" muss sich eine Klasse/Struktur/Union befinden.

    1>.\winutil.cpp(2106) : error C2228: Links von ".peRed" muss sich eine Klasse/Struktur/Union befinden.

    1>.\winutil.cpp(2107) : error C2228: Links von ".peGreen" muss sich eine Klasse/Struktur/Union befinden.

    1>.\winutil.cpp(2107) : error C2228: Links von ".peGreen" muss sich eine Klasse/Struktur/Union befinden.

    1>.\winutil.cpp(2108) : error C2228: Links von ".peBlue" muss sich eine Klasse/Struktur/Union befinden.

    1>.\winutil.cpp(2108) : error C2228: Links von ".peBlue" muss sich eine Klasse/Struktur/Union befinden.

    1>.\winutil.cpp(2124) : error C2228: Links von ".peFlags" muss sich eine Klasse/Struktur/Union befinden.

    1>wxdebug.cpp

    1>.\wxdebug.cpp(534) : warning C4996: '_vsnwprintf' wurde als veraltet deklariert

    1> C:\Programme\Microsoft Visual Studio 8\VC\include\stdio.h(450): Siehe Deklaration von '_vsnwprintf'

    1> Meldung: "This function or variable may be unsafe. Consider using _vsnwprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_DEPRECATE. See online help for details."

    1>.\wxdebug.cpp(567) : error C4430: Fehlender Typspezifizierer - int wird angenommen. Hinweis: "default-int" wird von C++ nicht unterstützt.

     

    And I have no idea, how to fix it, please help.

    Thursday, September 07, 2006 8:24 AM
  • It would help a great deal if you could paste whatever is at the lines referenced in the error messages.
    Thursday, September 07, 2006 8:32 AM
    Moderator
  • Hi all,

    I'm trying to compile the BaseClasses but I have the same problem (this time in english):

    ------ Build started: Project: BaseClasses, Configuration: Debug Unicode Win32 ------

    Compiling...

    wxdebug.cpp

    .\wxdebug.cpp(564) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

    winutil.cpp

    .\winutil.cpp(2104) : error C2065: 'Count' : undeclared identifier

    .\winutil.cpp(2106) : error C2228: left of '.peRed' must have class/struct/union

    .\winutil.cpp(2106) : error C2228: left of '.peRed' must have class/struct/union

    .\winutil.cpp(2107) : error C2228: left of '.peGreen' must have class/struct/union

    .\winutil.cpp(2107) : error C2228: left of '.peGreen' must have class/struct/union

    .\winutil.cpp(2108) : error C2228: left of '.peBlue' must have class/struct/union

    .\winutil.cpp(2108) : error C2228: left of '.peBlue' must have class/struct/union

    .\winutil.cpp(2124) : error C2228: left of '.peFlags' must have class/struct/union

    outputq.cpp

    .\outputq.cpp(664) : error C2065: 'iDone' : undeclared identifier

    Generating Code...

    Build log was saved at "file://c:\Archivos de programa\Microsoft DirectX SDK (June 2006)\Extras\DirectShow\Samples\C++\DirectShow\BaseClasses\Debug_Unicode\BuildLog.htm"

    BaseClasses - 10 error(s), 0 warning(s)

    ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

    I was looking around to get help but didn't find anything. I left empty the "Additional Include Directories", change the order of the "Include Directories" lines to put first those corresponding to Windows Platform SDK, but still get the same error again and again.

    My configuration: Visual C++ 2005 Express Edition, Microsoft Platform SDK for Windows Server 2003 R2 (March 2006), DirectX SDK (August 2006) plus Extras (January 2005).

    I'm trying to build AMCap sample from the Extras. After many troubles I could compile AMCap source, but failed at linking time because the need of compiled BaseClasses....

    Please, someone from MS can help us

    Thursday, September 07, 2006 1:42 PM
  • Hi everybody

    I have solved this problem on my visual studio environment.

    to solve change the order of the  include VC project directory. Go to  Tools>Options>Projects & Solutions Directory of VC++, Select in combobox win32 and includes directories

    Before I have (he don't works)
    C:\DXSDK\Include
    $(VCInstallDir)include
    $(VCInstallDir)atlmfc\include
    $(VCInstallDir)PlatformSDK\include
    $(FrameworkSDKDir)include

    Now i solve the problem with the order of directx SDK
    $(VCInstallDir)include
    $(VCInstallDir)atlmfc\include
    $(VCInstallDir)PlatformSDK\include
    $(FrameworkSDKDir)include
    C:\DXSDK\Include

    good luck
    Tuesday, September 12, 2006 12:30 PM
  • >>

    My configuration: Visual C++ 2005 Express Edition, Microsoft Platform SDK for Windows Server 2003 R2 (March 2006), DirectX SDK (August 2006) plus Extras (January 2005).

    I'm trying to build AMCap sample from the Extras. After many troubles I could compile AMCap source, but failed at linking time because the need of compiled BaseClasses....

    <<

    I should note here what has emerged in another thread I had started shortly after this one.  It turns out that the PSDK 2003 is geared to 64-bit programming specifically, so at one point or another you are bound to fail for that reason, if you are targeting the "ordinary" 32-bit Windows.  Thus it seems like you'll have to use Visual C++ 2005 instead of Visual C++ 2005 Express.

    I had managed to compile the BaseClasses just fine and stumbled over a missing atlthunk.lib when linking.  My PSDK and DirectX pieces were not as new as you are quoting.

    I have abandoned any effort to compile amcap with VC++ 2005 Express partly also because the application had, and still has, no urgency for me.

    Sorry for bringing bad news.

     

    Cheers,           Jochen

    Friday, September 15, 2006 11:38 PM
  •  Stewart Tootill wrote:
    I've had this problem too, and have found that the solution is to remove the DXSDK include directory from the projects additional includes (in the project settings). The projects additional includes are searched first - typically before the platform SDK, and my DXSDK has a basetsd.h in it, which is not compatible with the winnt.h in my platform sdk.

    Maybe this helps?


    Stewart is right ,i solved the same problem.

    but this time I am trying  to  compile the same code using makefile
    .I get the same problem.

    so how can I change the 
    include directory order in the command line?

    any help will be appreciated:)
    Monday, November 27, 2006 11:43 AM
  • I got this error while compiling an old project with Visual Studio 2005 for the first time.  The project had it's own copy of the DirectX headers.  Once I updated the DirectX headers, the problem went away.

    Vince

     

    Tuesday, February 06, 2007 7:35 PM
  • this thread is correct.

    the include folder order is problem.

    Saturday, February 17, 2007 2:15 PM
  • Insert

    #include <BaseTsd.h>

    into your project.

    Friday, March 09, 2007 12:51 AM
  •     I am getting the following issues when I try to build:


    c:\program files\microsoft platform sdk\include\winnt.h(3858) : error C2146: syntax error : missing ';' before identifier 'ContextRecord'
    c:\program files\microsoft platform sdk\include\winnt.h(3858) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    c:\program files\microsoft platform sdk\include\winnt.h(3858) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
    c:\program files\microsoft platform sdk\include\winnt.h(8320) : error C2065: 'PCONTEXT' : undeclared identifier
    c:\program files\microsoft platform sdk\include\winnt.h(8321) : error C2146: syntax error : missing ')' before identifier 'ContextRecord'
    c:\program files\microsoft platform sdk\include\winnt.h(8321) : warning C4229: anachronism used : modifiers on data are ignored
    c:\program files\microsoft platform sdk\include\winnt.h(8321) : error C2182: 'RtlCaptureContext' : illegal use of type 'void'
    c:\program files\microsoft platform sdk\include\winnt.h(8321) : error C2491: 'RtlCaptureContext' : definition of dllimport data not allowed
    c:\program files\microsoft platform sdk\include\winnt.h(8321) : error C2059: syntax error : ')'
    c:\program files\microsoft platform sdk\include\winnt.h(9595) : error C3861: '__readfsdword': identifier not found

    I have tried alot of the things people have posted before. They have not seemed to help. Anyone knows how I could fix this?

    thanks.
    Tuesday, May 08, 2007 8:57 PM
  • ArjCoder,

     

    you need to post information about which compiler version you are using, which additional SDKs and other pieces you are using and what their version and date is.  It would also be helpful to indicate where the code comes from that you are trying to compile.  Without that, all anybody can do is speculate, and so I am doing a bit of that here.

     

    My C2146 error was due to a bad sequence of libraries.  Go back and read the details in my second post in this thread.

     

    The C4430 errors can probably be due to a variety of conditions, probably some variation of the following:  You may have code that was developed with and/or for VC++ 6 and are trying to compile with VC++ 2005.  There was a major shift in C++ standard observance in the VC++ compiler between those two version, which necessarily has broken some good amount of code because VC++ 6 was in a variety of places at odds with the C++ standard.

     

    Start with those considerations and you may be able to at least reduce the number of errors you are getting significantly.

     

    Cheers,                   Jochen

    Tuesday, May 08, 2007 10:36 PM
  • Hi Jochen,

    thanks for your reply.

    I was using the latest Visual C++ 2005 express and had both psdk server 2003 r2 and sp1 installed just to check if either of the winnt.h files worked.

    I uninstalled everything and I will reinstall it again. The code which I am trying to compile was initally developed in Visual C++ 2005 express as well, but was never compiled!

    I had earlier installed the psdk r2 by following the same techniques as described in the document. So i think the paths were in the correct order, the sdk paths, i.e. lib,incl, and bin which they mentioned we should add from tools->options..

    I will reinstall and see if it works.
    Wednesday, May 09, 2007 6:45 AM
  • OK I'm completley confused and am hoping someone can explain just how exactly to fix these errors...

     

    C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(222) : error C2146: syntax error : missing ';' before identifier 'PVOID64'

    C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(222) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

    C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(5940) : error C2146: syntax error : missing ';' before identifier 'Buffer'

    C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(5940) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

    C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\include\winnt.h(5940) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int

     

    It seems like you guys have explained it but I just kind of need step by step instructions?  And I was wondering why this error is still around, why hasn't Microsoft patched this?

     

    Thanks,

    Brian

    Monday, July 16, 2007 2:48 AM
  • Yes, this does work.

    Thursday, August 02, 2007 3:06 AM
  • This is indeed the problem. The DirectX Include directory contains an early version of BaseTsd.h which does not include the definition for POINTER_64. You should instead use the version of BaseTsd.h in the Platform SDK, either the one that ships with Visual Studio 2005 (C:\Program Files\Microsoft Visual Studio 8\VC\PlatformSDK\Include\BaseTsd.h) or in an updated Microsoft SDK installation. In order to get the compiler to use the right file, just remove BaseTsd.h from the DirectX Include directory.

    Simple enough?
    Wednesday, October 24, 2007 2:19 PM
  • Finally, someone lucid. 

     

    Not positive, but I'm pretty sure this problem was

    introduced when I installed DirectX SDK (August 2007). 

     

    Changing "BaseTsd.h" to "BaseTsdORIGINAL.h" did work for me. 

    (I do hate modifying Microsoft's system however...  By adding the
    ORIGINAL string, I will be able to find and revert the file if I ever

    need it in the future...)

     

    Thanks,

     

    Howard

    Thursday, November 01, 2007 2:51 PM
  • I had the very same problem and this fixed it with out any modification to files. I simply moved the DXSDK includes to the bottom of the list. Problem solved.

     

    Thanks

     

    Sunday, February 17, 2008 10:42 PM
  • The renaming of BASETSD.H worked for me, Thank you

    Sunday, March 09, 2008 12:00 PM
  • Hi everybody

    I have solved this problem on my visual studio environment.

    to solve change the order of the  include VC project directory. Go to  Tools>Options>Projects & Solutions Directory of VC++, Select in combobox win32 and includes directories

    Before I have (he don't works)
    C:\DXSDK\Include
    $(VCInstallDir)include
    $(VCInstallDir)atlmfc\include
    $(VCInstallDir)PlatformSDK\include
    $(FrameworkSDKDir)include

    Now i solve the problem with the order of directx SDK
    $(VCInstallDir)include
    $(VCInstallDir)atlmfc\include
    $(VCInstallDir)PlatformSDK\include
    $(FrameworkSDKDir)include
    C:\DXSDK\Include

    good luck


    This is indeed very helpful to me:
    1. Make sure both "lib directory" and "include directory" have include your "C:\DXSDK\lib" and "C:\DXSDK\Include";
    2. Make sure the orders, both of the newly included directories should be put at the bottom line in the order;
    3. Make sure "additional include directory" of projects are empty;

    The above steps have indeed solved my problem.
    Thanks for all your answers, very helpful.

    Best Regards,
    Tintin
    Beijing, China


    Thanks.
    Wednesday, April 01, 2009 5:57 AM
  • Wow, I was having similar problems, and thanks to some of the above comments I was driven to look into basetsd.h. On my box, located at C:\Program Files\Microsoft SDKs\Windows\v6.0A\Include, BaseTsd.h was 0k (zero kilobytes). Yes, it was completely empty. I built my C++ projects just fine two days ago, I have not installed anything (like DirectX SDK). The timestamp of BaseTsd.h also was not altered, it matched the other files in the Include folder - 9.27.2007, 3:19pm. I was able to copy an 11k BaseTsd.h from a co-worker (whose timestamps were the same except 2:19pm, probably just a daylight savings time offset). At least I'm up and running again, but I don't think I will be sleeping well tonight... I'm scared.
    Wednesday, July 28, 2010 11:05 PM
  • Check your macro definition carefully

    it must be as shown below

    #define POINTER_64 __ptr64 //correct definition

    and not

    #define POINTER_64 __ptr64; // (wrong)

    ending macro definition with semicolon ends up in this situation usually

    • Proposed as answer by Derric Lyns Thursday, December 30, 2010 8:04 PM
    Thursday, December 30, 2010 8:04 PM
  • Check your macro definition carefully

    it must be as shown below

    #define POINTER_64 __ptr64 //correct definition

    and not

    #define POINTER_64 __ptr64; // (wrong)

    ending macro definition with semicolon ends up in this situation usually

     

    winnt.h header file might be missing the definition of POINTER_64 and it must be defined right above the declaration of PVOID and PVOID64 pointer datatypes as shown below. Find them and add definition for POINTER_64 correctly without semicolon.

    typedef void *PVOID;

    typedef void * POINTER_64 PVOID64;

    • Proposed as answer by Derric Lyns Thursday, December 30, 2010 8:14 PM
    Thursday, December 30, 2010 8:05 PM
  • Check your macro definition carefully

    it must be as shown below

    #define POINTER_64 __ptr64 //correct definition

    and not

    #define POINTER_64 __ptr64; // (wrong)

    ending macro definition with semicolon ends up in this situation usually

     

    winnt.h header file might be missing the definition of POINTER_64 and it must be defined right above the declaration of PVOID and PVOID64 pointer datatypes as shown below. Find them and add definition for POINTER_64 correctly without semicolon.

     

    typedef void *PVOID;

    typedef void * POINTER_64 PVOID64;

    • Proposed as answer by Derric Lyns Thursday, December 30, 2010 8:16 PM
    Thursday, December 30, 2010 8:16 PM