#undef

This is a discussion on #undef within the C++ Programming forums, part of the General Programming Boards category; I'm having trouble with #undef... it doesn't seem to be changing anything... at the top of my header file I ...

The preprocessor runs before the compiler, so preprocessor directives are run before your code is compiled. I'm not sure how much this helps, but I didn't take the time to fully understand your problem. It's late

"The computer programmer is a creator of universes for which he alone is responsible. Universes of virtually unlimited complexity can be created in the form of computer programs." -- Joseph Weizenbaum.

"If you cannot grok the overall structure of a program while taking a shower, you are not ready to code it." -- Richard Pattis.

But it might still not help you. I don't know what BOOST_ANY_TYPECHECK does, but if it changes the behaviour of the boost headers then undefining or defining it for one of your functions makes no difference. It only makes a difference at the point where you include the boost headers. Like with the windows header and _WIN32_LEAN_AND_MEAN: