in reply to How many ways are there to use AUTOLOAD?
It would be nice if perl had a 'use strict qw(methods);' mode for detecting as many of these issues as possible at compile time (of course you'd also have to be disciplined about declaring variable types) instead of having to deferr them to run-time.
I usualy put that kind of AUTOLOAD into the base class for all my objects.
As far as using AUTOLOAD to do anything else I usualy avoid it as it can make for harder to maintain and understand code in my opinion. There are some places where it can be very useful but I don't find myself using it too frequently (more often I will use code generation for refactorable syntax).
Kyle
|
|---|