How to get string for current namespace in Macro

c++, c-preprocessor, macros, namespaces

Solution

Can't work. Namespaces are recognized by the compiler, which runs only after the preprocessor.

Problem

I need to put namespace prefix in macros. I.e. ``` #define MYMACRO(x) ....##x namespace A { namespace B { MYMACRO(C); } } ``` and MYMACRO must return - A::B::C?

Original source

Related problems