Yes, that’s exactly my problem. I usually think it’s much more of a complex error where I’ve written my regex wrong. But it’s usually just a missing parthenses or the lack of a semi-colon at the end of line.
To debug, I usually run them through the command line too. I usually try and execute the file, via
and I run it through the Perl syntax checker,
perl -c script.pl
I always run my code using -W or (-w for more complex ones ) and use strict;.
To figure this one out… I downloaded ActivePerl for Win32 which forced me to change the shebang line to c:/perl/bin/perl and then the code executed fine. I then manually re-wrote the shebang and moved it back to my linux box and then that’s where that little dog jumped up and barked “bingo”! .
I’ll know from now on. I’ve just never encoutered such an error in years of programming, because I usually just cut and paste the first few lines of code containing copyright information and what-not anyway.
Ah well, back to work. I’ve ordered myself a brand spanking new machine today - well the parts anyway. Have to go out and buy a miditower and a motherboard to put the thing together over the weekend. :-))