Note: I have as first line of script:
                #!perl 
        and usually have -w
        If I have -w then I get the warning, without I get no warning at all.
        
        So maybe one of the gurus can tell us do you need some type of brackets or 
???? to get the warning if you use warnings vs -w in hashbang line.

Wags ;) ps Sorry for quick post and the followup.

-----Original Message-----
From: Gibbs Tanton - tgibbs [mailto:[EMAIL PROTECTED]]
Sent: Friday, November 09, 2001 14:20
To: '[EMAIL PROTECTED]'
Subject: constant redefinition does not produce a warning


Does anyone know why the following:

use strict;
use warnings;

use constant I => 1;
use constant I => 2;

print I();

does not produce a warning about the redefinition of I?  That is a real pain
as I had about 60 constants and had one redefined and never knew it until it
became a real pain to fix.  I'm running perl 5.6.1.  Does anyone know if it
warns on a newer version?

Thanks!
Tanton

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to