|We don't bite newbies here... much|
Re^4: Surviving 'Illegal division by zero'by ViceRaid (Chaplain)
|on Jun 23, 2004 at 22:17 UTC ( #369192=note: print w/replies, xml )||Need Help??|
And, this is the way to "directly re-open the method definitions". In fact, it's safer to do it this way than it is to redefine it for the whole program. That kind of "action-at-a-distance" is the source of more maintenance nightmares than anything else.
Totally agree. Before Abigail's post I hadn't really thought of it in OO (obj-oriented and op-overloading) terms. To put what you're saying in, uh, ahem, pseudocode, it's the difference between globally redefining a core method
and subclassing, which is all good
A last concept to leave you with - if someone were to take your code and wrap it in something else, which is the politer way to handle things?
Sure, it's a library. I was wondering if there was something scoped lexically analogous to:
In Section Seekers of Perl Wisdom