Steve Purkis asked:

Will generated accessors be overridable?

Indeed they will. If the class has an explicitly declared method of the same name, that method will prevent the accessor from being generated. And, of course, accessors are just methods, so derived classes can override them in the normal polymorphic fashion.



I can see how 'given' would be useful, but what if I wanted to say this:

    $grunt.name( "Patton" )
          .rank( "General" )
          .add_medal( "Purple heart" );

Then you'd write the class that way, with explicit C<name>, C<rank>, and C<add_medal> methods.



And have you considered a twisted lvalue form like:

    $grunt.name = "Patton"
          .rank = "General"
          .medals += ("Purple heart");

We certainly considered it. Which is why we went with C<given> instead. ;-)


Damian




Reply via email to