Is there such macro in C++ (cross-compiler or compiler-specific):
#if isclass(NameSpace::MyClass)
Would be useful.
There is no such thing at the preprocessing stage, so no macro.
However you can have a look at the is_class type traits available in Boost or in C++0x that enable you to take decisions at compile time.
is_class