On 2009-Aug-19, at 4:37 pm, Kevan Benson wrote:
I'm aware there's a default constructor that allows named parameters to be set, but I think the usefulness of allowing specific constructors that take defined parameters and initialize the object as needed should not be overlooked. E.g.
   my DateModule $d .= new('2007-03-12');

My first thought is also coercion: say my DateModule $d = '2007-03-12' and let DateModule::&.(Str) worry about making the new object.

(Or does that need to be my DateModule $d = DateModule('2007-03-12')? That seems unnecessarily redundant.)


-David

Reply via email to