On Tue, Nov 06, 2007 at 11:00:48AM -0500, John Peacock
wrote:
> Josh Jore wrote:
>> It breaks method calls by names. That's the point.
If I ask ->can()
>> and get a function back, I don't ever check that
the function is
>> defined. Mostly I assume it's defined. It never
would have occurred to
>> me that ->can and ->foo would find these
ghostie little methods.
>> &foo;
>
> What is the justification for the above line in real
code? This is the
> real problem, not anything to do with the rest of the
example code you
> gave.
>
> This is the piece of the puzzle that *many* people
tried to get Ms. Walsh
> to understand - you can't just take references of
possibly undefined
> function names and expect everything to Just Work(TM).
It isn't a bug in
> Perl, it is a "Carbon-base error".
Ok, I don't think it's a user error. Taking references to
functions
that don't exist yet is a normal part of perl. Of course you
can't
call them directly. Sure. I just wouldn't expect the action
at a
distance to interfere with MRO.
--
Josh
|