[cxxmodules] Fix failing execNestedClasses test for modules
[cxxmodules] Fix failing execNestedClasses test for modules

We needed to save and restore fHeaderParsingOnDemand value when exitting
RegisterModule function, so as not to enter wrong branch here: https://github.com/root-project/root/blob/master/core/metacling/src/TCling.cxx#L5899

Patch by Vassil and me.

karies/root,olifre/root,root-mirror/root,karies/root,karies/root,root-mirror/root,olifre/root,root-mirror/root,root-mirror/root,karies/root,root-mirror/root,olifre/root,root-mirror/root,olifre/root,olifre/root,karies/root,karies/root,olifre/root,root-mirror/root,karies/root,olifre/root,karies/root,karies/root,root-mirror/root,root-mirror/root,olifre/root,olifre/root,karies/root,root-mirror/root,olifre/root,karies/root,root-mirror/root,olifre/root