Subject: | leftover code in get_simple |
It seems that after switching to use @_ directly instead of using
lexical vars (ie. my ($self, ...) = @_;) there're two lines of old code
left behind in get_simple(). (Seems to be a mistake during a merge.)
Removing them results in ~5% performance gain on my 5.8.8 Perl (running
10000000 get_simples in a loop). :-)
Subject: | cag-get_simple-fix.patch |
--- 1/Class/Accessor/Grouped.pm 2008-01-10 01:37:14.000000000 +0100
+++ 2/Class/Accessor/Grouped.pm 2008-11-17 13:07:47.000000000 +0100
@@ -243,8 +243,6 @@
=cut
sub get_simple {
- my ($self, $get) = @_;
- return $self->{$get};
return $_[0]->{$_[1]};
}