Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options

Re: Re: Re: Re (tilly) 2: Paradigm Shift - Dual Use Constructors

by demerphq (Chancellor)
on Feb 20, 2002 at 09:59 UTC ( #146537=note: print w/replies, xml ) Need Help??

in reply to Re: Re: Re (tilly) 2: Paradigm Shift - Dual Use Constructors
in thread Paradigm Shift - Don't use strict

Hmm. Interesting angle. But ircc (its on my home computer) the code went more like
sub new { my $proto=shift; my $class=$proto || ref $proto; my $self=bless {},$class; if ($class eq $proto) { #class call $self->init_rand(); } elsif (@_) { $self->init_cross($proto,shift); } else { $self->init_mutate($proto); } return $self }
So the dreaded line was/is present. But you are correct I did/would comment this.

Yves / DeMerphq
When to use Prototypes?

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://146537]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (10)
As of 2016-10-26 11:21 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (340 votes). Check out past polls.