Problems with interrogating wglStateGraphicsGuardian

The problem is actually the line before, I think:

typedef __int32 int32_t;

The problem is that __int32 is a windows-specific type, it’s not part of the C++ language specification, so interrogate doesn’t know what it is and can’t figure out the typedef. The same would be true of the __int64 line, except that we explicitly add the flag “-longlong __int64” to the interrogate command line, which tells it to understand __int64 as the “long long” type. (Don’t know why Microsoft decided it needed its own nonstandard type names, but that’s Microsoft for you.)

The bigger issue, though, is that glext.h was never meant to be parsed by interrogate, and might have many other problems as well, with this or other similar Windows-specific code. We usually solve this problem by bracketing the relevant code with #ifndef CPPPARSER … #endif (you could protect the include panda_glext.h line this way, for instance), or we shadow the whole file by creating a dummy file in parser-inc, which interrogate will read instead of the actual file. I’m not sure if the parser-inc trick will work for a file within Panda’s own source tree, though.

David