NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.
All the Perl that's Practical to Extract and Report
Stories, comments, journals, and other submissions on use Perl; are Copyright 1998-2006, their respective owners.
Badger::Class also makes this easy (Score:1)
The code sample you posted is almost there. You just need to create an anonymous package name instead of using
__PACKAGE__. I would simply append the accessor names to the base class, e.g.Object::Anonymous_ding_wong_linesub new {
my $class = shift;
my %args = @_;
my $self = { };
my $name = join('_', $class, keys %args);
for my $arg (keys %args) {
Re:Badger::Class also makes this easy (Score:1)
s/Auto/Anon/ # cut and paste failReply to This
Parent