in reply to Re^2: perl inheritance
in thread perl inheritance
Would you have the constructor take a base class object and convert it to the derived?
I'd get the class of the provided object, then call its constructor directly.
Something like the following...
No. You're overcomplicating this and confusing yourself. Please post the existing code that constructs a new object so we can all see what you're doing.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: perl inheritance
by Anonymous Monk on Mar 26, 2012 at 14:07 UTC | |
by chromatic (Archbishop) on Mar 27, 2012 at 16:19 UTC | |
by Anonymous Monk on Mar 29, 2012 at 14:43 UTC | |
by Anonymous Monk on Mar 29, 2012 at 15:39 UTC | |
by tangent (Parson) on Mar 29, 2012 at 16:11 UTC |