While I can understand that RBProgramNodeVisitor >> visitMethodNode: 
aMethodNode does not return a value. 
- because visiting a program does not mean automatically to interpret it. 

RBProgramNodeVisitor >> visitMethodNode: aMethodNode
        self visitArgumentNodes: aMethodNode arguments.
        aMethodNode pragmas do: [ :each | self visitNode: each ].
        self visitNode: aMethodNode body

I was wondering if we could have visitBody

RBProgramNodeVisitor >> visitMethodNode: aMethodNode
        self visitArgumentNodes: aMethodNode arguments.
        aMethodNode pragmas do: [ :each | self visitNode: each ].
        self visitBody: aMethodNode


RBProgramNodeVisitor >> visitBody: aMethodNode
        self visitNode: aMethodNode body
        

So that subclasses can simply override it instead of being forced to override 
visitMethodNode: ?

https://github.com/pharo-project/pharo/issues/5521

S


--------------------------------------------
Stéphane Ducasse
http://stephane.ducasse.free.fr / http://www.pharo.org 
03 59 35 87 52
Assistant: Julie Jonas 
FAX 03 59 57 78 50
TEL 03 59 35 86 16
S. Ducasse - Inria
40, avenue Halley, 
Parc Scientifique de la Haute Borne, Bât.A, Park Plaza
Villeneuve d'Ascq 59650
France

Reply via email to