Denis Kudriashov wroteA traverser doesn't have to be a lot of work;>> Would it?
>> With pure method tags, you'd do something like:
>> SomeClass >> #renamePackage: aPackage
>>
> <command: 'Rename package'
>>
>�� ��category: 'Package'
>>�� order: 25
>>�� shortcut: #($r meta)>
>> ... method renaming package here ...
>
> Then have different pragma traversers capable of creating the actual menus
> /
>> commands invoking such methods.
>>
>
> So instead of simple subclassing of ClassAnnotation you would suggest me
> to
> implement pragma traversal/interpreter?
> I would prefer first. It gives me for free the object with any structure
> without any tricky literal interpretation logic.
> For me annotation is just obviously simpler solution.
http://forum.world.st/Having-comments-for-pragma- tp4902987p4903058.html
Denis Kudriashov wrote
> Also try to think how to support blocks in parameters with pragma
> approach.
> And how fun would be to debug them.
>�� It is for the question about
> "restricted anyway".
You wouldn't need them. What to do with the tag, is up to the traverser.
For instance, #perform'ing one of the literal args on the domain class
traverser creates, returning an appropriate block, if strictly necessary.
Denis Kudriashov wrote
>�� Really, with annotations you have normal smalltalk
> code for annotating classes. No magic. And implementation is really
> simple.
Same with a traverser; the normal smalltalk code to create your domain
objects�� is simply in a different place; the traverser part of the package
defining said domain, rather than as an extension method marked with a tag.
I guess it's best to just agree to disagree, and since you're the one
implementing... ;)
Looking forward to trying it out!