Think about Loose Coupling | |
PerlMonks |
Interesting: a genuine Perl-bugby sundialsvc4 (Abbot) |
on Sep 22, 2010 at 13:04 UTC ( [id://861269]=perlquestion: print w/replies, xml ) | Need Help?? |
sundialsvc4 has asked for the wisdom of the Perl Monks concerning the following question: Wow. I just encountered my first bona-fide bug in Perl. (“ v5.10.0 built for aix-64all”)
I encountered the following message and could not make it go away:
But in the line cited by the message, state was obviously not a bareword:
Finally, somewhat in desperation now, I enclosed the line with statements to suppress the error:
And this time when I checked the syntax, I got a different message:
And, voilá! A bareword occurrence of the variable state did exist... Okay, sure... it’s a very small insect. The syntax error that Perl had caught did, in fact, exist. But it did not occur at the location cited in the message. (The message seems to have cited the first line, other than the variable-declaration itself, where the offending variable was used.) So... the take-away for all this is... “just be aware of it.”
Back to
Seekers of Perl Wisdom
|
|