and since i'm also using poe, i was glad to find the illicit love child of moose and poe - aka moosex::poe. declaring an event without any fuss:has foo => ( is=>'ro', ... );
but when your module grows to have lots of attributes and poe events, it's difficult to go directly to a given definition in the file.event frobnize => sub { say $_[0]->foo };
readers of this blog know that i'm using padre (the perl ide), but neither the sub nor the outline views can help. indeed, if you look the code snippets above, there is no traditional sub definition... syntaxic sugar is nice, but it means the tools need to be aware of them.
this was clearly an itch to scratch... i had a look at padre's outline code, and after some help from alias, here's the result:
the patch is surprisingly small: around 20 lines for attribute detection, and the same for event detection... that's the beauty of having cpan modules at hand - the great ppi in this case.
(note: the feature is in trunk currently. you'll have to wait 0.38 release)
so, try padre. tell us which feature it lacks. or how can we make it the modern perl editor, the one that would be recommended alongside moose and others.
jquelin++. Really awesome. I wonder if we could also get more Moose stuff in there like methods, inheritance and roles. This will bridge a gap between Padre's Perl 5 and 6 support.
ReplyDelete