| f g h | f := '[ :a | ^a + 1 ].'. " Message pattern expected " g := '| b |'. " '|' expected " h := '| b ||'. " Success?!? " OpalCompiler compile: f. OpalCompiler compile: g. OpalCompiler compile: h.
Basically I went from writing a function to clean up StringMorphs on the World... cleanupStringMorph "Clean up string morph in world." | x y | x := World submorphs. y := [ x select: [ :each | (each isMemberOf: StringMorph) ] ]. y value do: [ :each | each delete ]. Smalltalk garbageCollect. ...to wondering how to generalize the idea (pass the class as an argument)... ...but that would be too easy, so why not manipulate the AST programatically... I read https://marcusdenker.de/publications/Bera13a-OpalIWST.pdf but the compiler thinks I am a fool :-( My guess is I need to know what are the method calls from text to AST to bytecode. Any idea? Victor RENESoftware engineer,Game designer, Writer Blog: http://victor-rene.comProjects: http://logiqub.com tel: +33 6 26 83 61 76email: victor-r...@outlook.com