home bbs files messages ]

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

   comp.compilers      Compiler construction, theory, etc. (Mod      2,753 messages   

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

   Message 822 of 2,753   
   Eric to moop   
   Re: Translating OO program to procedural   
   11 Oct 06 23:20:10   
   
   From: englere_geo@yahoo.com   
      
   moop wrote:   
      
   > My approach is just to rename the methods with the instance name so   
   > that they can be placed in a single source file and then be compiled   
   > later by the procedural lang compiler.   
      
   This can get nasty with instances being created dynamically. I can   
   create hundreds of instances at runtime, and you won't know this at   
   compile time. You would have to implement the "new" mechanism yourself,   
   and you'd have to track the locals for all of my instances dynamically.   
   This is far more complicated than a simple text translation.   
      
   The only option that makes sense to me if to use a C++ compiler that   
   produces an output in the form of C code - C would be the target   
   language. This would be a full compiler and not a simple program.   
      
   --- 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