Find variable at run time
    Dicebot 
    m.strashun at gmail.com
       
    Sat May 18 01:26:08 PDT 2013
    
    
  
On Saturday, 18 May 2013 at 02:09:49 UTC, Josh wrote:
> Bearophile, is your findVar an AA? It looks like it is, I just 
> didn't think you could put refs in an AA.
>
> Thanks
>
> Josh
It is AA and it stores pointers, not references.
P.S. There can be found a lot of solutions but they will all do 
some kind of adding extra run time information, be it "if" chain 
or AA map. Local variable names exist only during compilation, in 
compiled binary those are just stack offsets so can't possibly 
find one based on run time value without that extra info.
    
    
More information about the Digitalmars-d-learn
mailing list