Post parse processing of the result comment placing as example
--------------------------------------------------------------

                 Key: JRUBY-1034
                 URL: http://jira.codehaus.org/browse/JRUBY-1034
             Project: JRuby
          Issue Type: Improvement
          Components: Parser
         Environment: Gentoo Linux / Windows Vista
            Reporter: Thomas Corbat
            Priority: Minor
             Fix For: JRuby 1.x
         Attachments: DefaultRubyParser.patch, postprocessing.patch

As announced on the mailing list, here is the patch which includes the 
postprocessing of the parser result. This contains a new interface 
PostProcessor which must be implemented by every post processor. The 
ParserConfiguration gets new methods to add and get such post processors. The 
ParserSupport has a new method to apply every post processor to the 
ParserResult.
As an example what a post processor could do there is the implementation of the 
commen node placing in the ast. (Mirko is about to implement the testing 
possibilities for the comment stuff.)
This is contained in the postprocessing.patch file.

The only thing which is not done yet is the call of the applyPostProcessors 
method of the ParserSupport. I didn't want to decide if it should be called at 
the end of the parse()-method of the DefaultRubyParser before returning the 
ParserResult or if it should be done by the user of the parser itself manually. 
My suggestion would be to do it in the Parser as the post processors could 
still be left out when none is added to the configuration. This is contained in 
the DefaultRubyParser.patch file.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email

Reply via email to