develooper Front page | perl.perl5.porters | Postings from March 2000

Re: [ID 20000330.052] Use of uninitialized value in concatenation (.)

Thread Previous | Thread Next
Tom Christiansen
March 30, 2000 20:14
Re: [ID 20000330.052] Use of uninitialized value in concatenation (.)
Message ID:
>Simply saying "use of uninitialized variable in line xxx" is fine, but
>once you start trying to tell the user what operator went wrong, you
>have to be accurate when you do so.

That *was* accurate.  They just are unable to understand that accuracy.

>I'm sure the patch for that would be a pain in the ass to implement.
>It might be the wrong trade-off in terms of performance.

>I just think that if you're going to try to tell the user what caused
>the error, you should tell them what actually caused it.  And since
>the user didn't use '.' in that spot, it would cause a lot of
>confusion trying to hunt it down.

Patches speak louder than words.  

>Also, remember that novices are often told to turn on warnings, and so
>they would be the most likely to be bit by this problem.

    use strict;
    use warnings;

It's more than just a good idea.


Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About