Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: Re: What is this can() and why is breaking it (un)acceptable?

by stvn (Monsignor)
on Apr 07, 2004 at 05:18 UTC ( #343192=note: print w/ replies, xml ) Need Help??


in reply to Re: What is this can() and why is breaking it (un)acceptable?
in thread Why breaking can() is acceptable

jonadab

To start with, your Camel book is out of date, but thankfully, http://www.perldoc.com is not. Here is a link to the UNIVERSAL page. You may find this enlightening.

As for my opinion (and I did make a point to say it was my opinion (note the "IMO")) about OO module designers obligations (please keep in mind it is specific to OO modules, as only blessed references inherit from UNIVERSAL). They are my opinions, you and the whole of the perl community have every right to dismiss them as the ravings of a lunatic (believe you wouldn't be the first).

But my assertion that it is bad OO design to break the a method in your base class through some fault of your subclass, actually has nothing (directly) to do with Perl at all. It is just OO design, sure its maybe strict OO design, which Perl is certainly not known for, but if you pick up any (good) book on the subject, I am sure you will find something similar to what I say.

-stvn


Comment on Re: Re: What is this can() and why is breaking it (un)acceptable?
Re: What is this can() and why is breaking it (un)acceptable?
by jonadab (Parson) on Apr 08, 2004 at 11:01 UTC
    your Camel book is out of date, but thankfully, http://www.perldoc.com is not.

    If I start using online docs, I'm going to end up wanting to keep every system up to date with the latest perl all the time. I was hoping to avoid that until Perl6 comes out. At present I use systems that have everything ranging from 5.005 through 5.6.1 to 5.8.1, and this has never proven to be a problem, not even when using a lot of modules off of the CPAN. I wouldn't want to start relying on all the latest features; that would be bad design for sure, and not only in terms of OO purity.

    In retrospect, my other post seems to have come across as a little harsh. For that I'm sorry. But I disagree that it's bad design to break something that's a fairly new feature anyway, within the same major version (Perl5).


    ;$;=sub{$/};@;=map{my($a,$b)=($_,$;);$;=sub{$a.$b->()}} split//,".rekcah lreP rehtona tsuJ";$\=$;[-1]->();print

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (7)
As of 2014-11-24 08:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (137 votes), past polls