2013/4/10 Dicebot <[email protected]> > On Wednesday, 10 April 2013 at 08:41:35 UTC, kenji hara wrote: > >> Sorry I have no answer for the issue. That is still unknown area to me... >> >> Kenji Hara >> > > Thanks for replying! Really appreciated. > > May be you can give me a small insight on dmd internal data representation > then? I think I have got the issue and know what needs to be done, but > can't find reasonably short solution within existing code structure. >
OK. I don't understand the issue enough, but I'd like to help you. - TemplateInstance::tinst may represent the enclosing template instance that 'this' instance is instantiated. It is set in TemplateInstance::semantic(|2|3) for its member's semantic process. - TemplateInstance::enclosing may represent the parent of nested template instance. If a template is instantiated in function scope with implicit context, it points the function. It is set in TemplateInstance::hasNestedArgs. - Module::importedFrom may represents the "root module" of import chain. it points one of the module that listed in command line. Good luck. Kenji Hara
