G_ClassInfo change?

I seem to remember that G_ClassInfo related things has changed a while ago, but couldn’t find what it was all about. I’m trying to recompile with ROOT 5 a code of mine that was running with ROOT 4 previously. I get the following error :

…/src/mysiesta/VViewerSelectorCint.h:27: error: `G__ClassInfo’ has not
been declared

I guess it’s just a change in name or location or whatever.

Any hints on what could be going on ?

Thanks a lot


Hi Damir,

check with g++ -E, but I think you’re missing an include file somewhere. You were probably #including Class.h indirectly with the old ROOT version, and now that we’ve cleaned up the #includes your source doesn’t see it anymore. Could that be it?


Hi Axel,

That is probably the case. I was including “Api.h”. With the (not so) new version I guess this is not enough. I was using cint to load and execute some code (“à la TSelector”) and I used the old ROOT code as an example. So I’m using things like G__dispmsg and G__ClassInfo.
I guess it should still work.

Anyway, I’m going to try with the inclusion of “Class.h”

Thanks a bunch


Hi Damir!

That should work just fine - I see Api.h includes Class.h. G__ClassInfo is now in the namespace Cint, but they all (e.g. Class.h) have a “using namespace Cint”, so you should not see any consequences from that… Can you send me the output of your attempt to compile the file that includes …/src/mysiesta/VViewerSelectorCint.h, only instead of “-c” to compile it you say “-E” so I can see what’s happening? Thanks!


Well, I managed to make it work. I was actually making a forward declaration of G__ClassInfo and it was not really working anymore. It is still a mess in my headers, but now it should work (hopefully).
No need to bother you !

Thanks again


Uh, that explains - so the reason is the namespace Cint - all of a sudden you had your own forward declared G__ClassInfo outside CINT. Phew, understood.