[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Output text from AST




Hi again,

I'd like to thank Thomas for his quick responce to my previous question.

Up till now, I have modified the Java grammer slightly, parsed a java
source program with this modified grammer, and then transformed the AST
in to a completely j11.sablecc compatible AST.

I was wondering if any one has previously created a "pretty printer"
adapter that traverses a standard Java AST and outputs the Java code.
Is there any standard way in which this can be done with out having
to write over-riding every production rule's method?  I'm just trying
to save myself from writing a heap of code here :)

Thanks in advance.

Regards,
Nick


-- 
Nicholas Read, BSc
Hobart, Tasmania
Australia

Email:  Nicholas.Read@utas.edu.au
Mobile: 0429-487-700
ICQ #:  20770226

"Bud, if dynamite was dangerous do you think they'd
 sell it to an idiot like me?"
   - Al Bundy, "Married with Children"