[squeak-dev] Getting rid of Display global
Igor Stasenko
siguctua at gmail.com
Sun Nov 9 01:01:24 UTC 2008
2008/11/9 Igor Stasenko <siguctua at gmail.com>:
> 2008/11/9 Lukas Renggli <renggli at gmail.com>:
>> http://www.lukas-renggli.ch/blog/ob-rb-3
>>
>
> Thanks for tip, (i found it before, but have no idea how to use it)
> in OB if i right-click on methods list, i can choose:
> open >> rewrite code
> or
> open >> search code,
>
> which replacing text in method source pane with, as i understand, a
> sample template for creating search/replace pattern.
> ---
> ParseTreeSearcher new
> matches: '`@object' do: [ :node :answer | node ];
> matchesMethod: '`@method: `@args | `@temps | `@.statements' do: [
> :node :answer | node ];
> yourself
> ---
> now, the problem is, that i don't understand what to do next, and
> can't actually find anything useful.
> Do it - nothing happens
> Accept it - nothing happens..
>
> i expecting to get a list of methods found with a nice 'Accept/Cancel'
> options which is shown on your screencast.. :)
>
> Can you help me please?
>
... to elaborate what i'm expecting to be easily done is to write a
snippet, like:
| rule |
rule = ParseTreeSearcher new blablabla .
OB showMeWhatYouFoundBasedOn: rule.
or , in case if i want to ship it in changeset (a non-interactive
version of changes), is something like:
| rule |
rule = ParseTreeRewriter new blablabla .
OB silentlyRewriteMethodsBasedOn: rule.
--
Best regards,
Igor Stasenko AKA sig.
More information about the Squeak-dev
mailing list
|