projects
/
spider.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
1. tidy up AUTOLOAD
[spider.git]
/
perl
/
DXUser.pm
diff --git
a/perl/DXUser.pm
b/perl/DXUser.pm
index cf847bc897778748295e61aa41d15962a8ef83a3..dec317a1928623ca40e004819cd473fdb53bda53 100644
(file)
--- a/
perl/DXUser.pm
+++ b/
perl/DXUser.pm
@@
-91,7
+91,6
@@
$lrusize = 2000;
#no strict;
sub AUTOLOAD
{
#no strict;
sub AUTOLOAD
{
- my $self = shift;
no strict;
my $name = $AUTOLOAD;
no strict;
my $name = $AUTOLOAD;
@@
-102,12
+101,7
@@
sub AUTOLOAD
# this clever line of code creates a subroutine which takes over from autoload
# from OO Perl - Conway
*$AUTOLOAD = sub {@_ > 1 ? $_[0]->{$name} = $_[1] : $_[0]->{$name}};
# this clever line of code creates a subroutine which takes over from autoload
# from OO Perl - Conway
*$AUTOLOAD = sub {@_ > 1 ? $_[0]->{$name} = $_[1] : $_[0]->{$name}};
- &$AUTOLOAD($self, @_);
-# *{$AUTOLOAD} = sub {@_ > 1 ? $_[0]->{$name} = $_[1] : $_[0]->{$name}} ;
-# if (@_) {
-# $self->{$name} = shift;
-# }
-# return $self->{$name};
+ goto &$AUTOLOAD;
}
#use strict;
}
#use strict;