in reply to Two argument bless syntax
What I don't see is why the author supposes $class might be a reference in ref $class || $class. The first argument to a constructor is usually always a literal string representing the class name and i'm betting that ref $class is redundant there as it evaluates to false.sub new { return bless {}, shift; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Two argument bless syntax
by johngg (Canon) on Nov 22, 2006 at 18:55 UTC |