I proposed another solution to get a "silent" constructor in my Dog $spot;. It involves merely naming the constructor MODIFY_SCALAR_ATTRIBUTES(). It almost works, but some dummy attribute must be cited for the constructor to be called,
MODIFY_SCALAR_ATTRIBUTES() could be written to take the constructor arguments, %options, from the attribute list, but that feels kind of dirty to me.use Some::Other::Class; my Some::Other::Class $obj :dummy;
After Compline,
Zaxo
In reply to Re: Getting rid of "new"
by Zaxo
in thread Getting rid of "new"
by xdg
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |