nimdokk has asked for the wisdom of the Perl Monks concerning the following question:
This is what I got for an error message:
Bareword found where operator expected at prog.pl line 1544, near ") NE" (Missing operator before NE?) syntax error at prog.pl line 1544, near ") NE " syntax error at prog.pl line 1548, near "else" Execution of dni aborted due to compilation errors.
This is what they are trying:
Now, I didn't fully check things out and concluded that they had meant to do != instead of NE. I didn't realize that "ne" was a string comparison, not a numeric even though it looked like they were trying to do a numeric comparison. I substituted in != and everything ran fine. However, I had an email from tech support that the version of Perl I was looking at (ActivePerl 5.8.0) didn't like the "NE" and that I should put in "ne" instead. I did this and it worked just fine. The only versions of Perl that I've looked at have been 5.8.0 (Windows and Unix, same errors with the "NE"). I checked through the Camel book and only find "ne" not "NE." Is there really a difference between the two? or am I losing it? Is there something perhaps in later builds of 5.8.0 that would account for this issue? Any thoughts anyone?while (($var1 = index ($var2, $var3)) NE -1 )
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Problem with case sensitivity?
by eserte (Deacon) on Apr 06, 2004 at 17:55 UTC | |
|
Re: Problem with case sensitivity?
by ambrus (Abbot) on Apr 06, 2004 at 18:02 UTC | |
|
Re: Problem with case sensitivity?
by Fletch (Bishop) on Apr 06, 2004 at 18:27 UTC | |
|
Re: Problem with case sensitivity?
by halley (Prior) on Apr 06, 2004 at 17:49 UTC | |
|
Re: Problem with case sensitivity?
by Aragorn (Curate) on Apr 06, 2004 at 19:53 UTC | |
|
[OT] Re: Problem with case sensitivity?
by saintbrie (Scribe) on Apr 06, 2004 at 22:54 UTC | |
|
Re: Problem with case sensitivity?
by nimdokk (Vicar) on Apr 07, 2004 at 09:46 UTC |