in reply to making perl more forgiving

I can't help it but to think of HTML here. MS Internet Explorer is very idiot-forgiving, meaning, if you write crappy HTML (and close half the tags you need to), IE will still show the result somewhat how the author intended it.

This contributed in the many horrible WYSIWYG editors spitting out horrible HTML... and the WYSIWYG-on-your-computer-only idea.

If you just write your perl code right, you won't need a forgiving interpreter. And the example you gave just shows me you rather want to be lazy than to actually debug your code.

--
b10m

All code is usually tested, but rarely trusted.

Replies are listed 'Best First'.
Re: Re: making perl more forgiving
by chanio (Priest) on May 16, 2004 at 19:24 UTC
    I see perl as a language. It could even be called like this...

    perl -RTFM myscript.pl

    And the compiler could suppose everything that is not stated or that is badly declared.

    But in the end, it is like people that use to say everything with only 100 words. (x.e.politicians, astrollogers, prophets,etc.). Everybody gets the illusion that they are saying what they want to hear. The level of effective comunication, is lowered at it's minimum.

    So, on the other hand, it may happen that one day I am speaking the truth about something, and everybody yet want's to punish me.

    There are times when precission is imperative.

    I believe that the level of effectiveness of a programming language resides in the limitations that the compiler imposses to the user. Yet, perl has done miracles in this aspect. So, it forgives a lot if you ignore the key words that gives you the required 'extra' precission.

    .{\('v')/}
    _`(___)' __________________________
Re: Re: making perl more forgiving
by jepri (Parson) on May 16, 2004 at 12:25 UTC
    Point taken about HTML, but don't we all want to be lazy? It's supposed to be one of the three virtues of a perl programmer ( laziness, impatience, hubris ).

    And in case chromatic thinks I'm taking credit for coining the virtues, I'll reveal here that it was actually Larry Wall who thought of them.

    ____________________
    Jeremy
    I didn't believe in evil until I dated it.

      Heh, laziness means not having to declare well-known sources. :)

Re: Re: making perl more forgiving
by hv (Prior) on May 16, 2004 at 21:40 UTC

    This is a very useful analogy, and serves to underline my initial reaction that improving perl's error recovery is a possible and useful thing to do, but that this particular example (of mismatched quotes) is probably a really bad example. Consider what IE (or any other browser) does if you inadvertently replace a tag-close '>' with, say, a '<'.

    Hugo