> On 27 Feb 2015, at 20:26, Marcus Denker <[email protected]> wrote:
>
>
>> On 27 Feb 2015, at 19:48, Thierry Goubier <[email protected]> wrote:
>>
>> Hi Markus,
>>
>> if I understand correctly some of the possibilities:
>>
>> - I can use RBParseTreeSearcher / RBParseTreeRewriter on the twin AST.
>>
>> (any example how to install / invalidate the twin AST after an effective
>> RBParseTreeRewriter operation?)
>>
> Yes, but I would do it on a copy… that is, do the change in run:with:in: on a
> copy, generate code from that,
> keep the original.
> An AST that follows the text is kind of nice for e.g. navigation
The reason is that we actually cache the AST if you request it from a
CompiledMethod, this means you do not
want to change that cached version as e.g. the Browser uses it for Navigation
or the “Suggestions” menu.
Marcus