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.
Hmmm. (Score:1)
It's a trade-off. If you write 'validate' such that it doesn't take argument, but calls 'user' on its first parameter, you have a function with a simpler interface. OTOH, the function is less general than it can be - all it can do is validate its own user. It also should have been named differently, f
Re:Hmmm. (Score:1)
A methodology of sticking everything thing in the object and then referencing it there is a close cousin to the evilness that is global variables.
However, if you code is full of $self->user always being passed to $self->validate.... there could be a problem.
Reply to This
Parent