home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.c++.moderated      Moderated discussion of C++ superhackery      33,346 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 33,100 of 33,346   
   Frank Bergemann to Paul D. DeRocco   
   Re: Access Data Items In Ancestor Stack    
   03 Jun 13 04:34:42   
   
   0b860dea   
   From: frank67x@googlemail.com   
      
   On 31 Mai, 10:00, "Paul D. DeRocco"  wrote:   
   > What's the type of "caller"? How can the compiler know what   
   > "caller->x" means unless it knows this? And if the only way to   
   > guarantee that the caller has an "x" of a particular type known to   
   > the compiler is to restrict the set of callers at compile time, that   
   > suggests a simpler solution: just pass x as a reference parameter.   
      
   If dealing with recursive tree evaluation, caller might be the same   
   function. Or alternating invocation with a well known companion   
   function. Whenever a tree algorithm uses parent, it can use caller   
   now. No need for extra storage, but using the stack. It could replace   
   dynamic memory allocation with data on the stack, where it might be   
   available first of all anyways. That's one reason i think it could be   
   useful.   
      
   regards,   
   Frank   
      
      
   --   
         [ See http://www.gotw.ca/resources/clcm.htm for info about ]   
         [ comp.lang.c++.moderated.    First time posters: Do this! ]   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca