On Tue Apr 01 18:37:43 2014, haarg wrote:
Show quoted text> On Sat Mar 15 15:42:11 2014, DJERIUS wrote:
> > It'd be nice if, similarly to how 'builder => sub{...}' is handled, a
> > coderef passed to 'trigger' would result in installation of the
> > coderef in $class::_trigger_${attr_name}.
> >
> > Thanks,
> > Diab
>
> trigger is more analogous to default than to builder. Without the
> shortcut, giving builder a sub is an error.
Ok, upon rereading the documentation and code, I see that the builder routine
is ultimately accessed by name, not by coderef; that's a significant difference
to how trigger is implemented.
Changing trigger to follow that behavior (which would be the only means of
ensuring there's no confusion over which code is run) would be detrimental.
So, I'll close this; sorry for the noise.
Diab