[Pharo-project] About RBProgramNodeVisitor interface
Hi all I was reading RBProgramNodeVisitor and I do not like the fact that we have name of the methods is not consistent with the GOF. I do not like that the visitor methods are named accept* and in addition the visitMethod of RB are not what you think they should. I know it was done before GOF but I would really like to clean that. I would like to have the visitMethod in the visitor and the accept in the Node. May be it would be better to rewrite another one and start to use it regularly. What do you think? Stef
What do you think?
It is uncommon. I shoot myself in the foot when implementing SmallWiki and following the RB visitor code. It is the hell lot of work to change that though. Numerous external project depend on these visitors and I am sure I forgot half of them: RefactoringBrowser, OB-Refactory, NewCompiler, Reflectivity, Persephone, QuasiQuoting, Diesel, ... Furthermore, if the interface is changed it won't be easily possible to port the latest version of SmaCC to Pharo anymore. Lukas -- Lukas Renggli http://www.lukas-renggli.ch
What do you think?
It is uncommon. I shoot myself in the foot when implementing SmallWiki and following the RB visitor code.
It is the hell lot of work to change that though. Numerous external project depend on these visitors and I am sure I forgot half of them: RefactoringBrowser, OB-Refactory, NewCompiler, Reflectivity, Persephone, QuasiQuoting, Diesel, ... Furthermore, if the interface is changed it won't be easily possible to port the latest version of SmaCC to Pharo anymore.
I do not understand the relation between Smacc and the visitor code? Smacc parse and produce the ast Do you mean the new compiler ast checker and other. Now it would be good that we move on. I will probably write a new visitor because I hate this code. May be other people will use it at least I will for my projects. I would like to know how we could automatically transform code from one to the others. else we will be stuck forever with this code. Stef
I do not understand the relation between Smacc and the visitor code? Smacc parse and produce the ast Do you mean the new compiler ast checker and other.
SmaCC has the RefactoringBrowser as a dependency. It uses it to build the parsers.
I would like to know how we could automatically transform code from one to the others. else we will be stuck forever with this code.
That's fairly easy to do with a custom refactoring. Lukas -- Lukas Renggli http://www.lukas-renggli.ch
So I will spend some time on the visitor I would like and come back to you. On Jan 22, 2009, at 11:24 AM, Lukas Renggli wrote:
I do not understand the relation between Smacc and the visitor code? Smacc parse and produce the ast Do you mean the new compiler ast checker and other.
SmaCC has the RefactoringBrowser as a dependency. It uses it to build the parsers.
I would like to know how we could automatically transform code from one to the others. else we will be stuck forever with this code.
That's fairly easy to do with a custom refactoring.
Lukas
-- Lukas Renggli http://www.lukas-renggli.ch
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
participants (2)
-
Lukas Renggli -
Stéphane Ducasse