[antlr-interest] Parallel source code parsing?

Jörg Rech rech at iese.fhg.de
Wed Aug 11 07:09:19 PDT 2004


Hi,
  I'm parsing sourcecode and need to extract the "normal" sourcecode 
as well as the AST from the code. Now I have the problem that while 
I can parse the code I additionally need to extract the code in raw 
ASCII without re-calculating the code from the AST.
 
For example, the result should look like this:
<Class name="c1" modifiers="a">
  <Inline-Class name="ic1" modifiers="a, b">
    ** SourceCode of Inline-Class with or without method code) **
  </Inline-Class>
  <Method name="meth1" modifiers="a, b">
    ** SourceCode of Method meth1 **
  </Method>
  ** SourceCode of Class c1 (with or without code from meth1) **
</Class>

Is it possible to copy code from the document during parsing and 
feed it to two different (sub-)parsers (e.g., one for AST generation 
and one for source extraction)? 
Has anyone a idea or solution that could help me?

Bye,
Joerg.




 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/antlr-interest/

<*> To unsubscribe from this group, send an email to:
    antlr-interest-unsubscribe at yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



More information about the antlr-interest mailing list