Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: unknown syntax

by furry_marmot (Pilgrim)
on May 01, 2012 at 20:38 UTC ( #968329=note: print w/replies, xml ) Need Help??

in reply to unknown syntax

If it's a .bat file, it's a Windows batch file. Before Windows XP, you might or might not have been able to successfully run a Perl script on windows just by running it. One solution was to convert a perl script to a batch file (the Activestate distribution still includes a script to accomplish this).

The script makes a copy of the perl script (replacing the extension with .bat) and puts a bunch of lines at the top so that if Perl is not installed, the batch file will exit gracefully. When you run the batch file, it calls perl.exe with the batch file as the argument, including the -x switch, which tells perl to skip everything until it finds a shebang line (which is #!perl).

And as JavaFan pointed out, local *MY_VAR is defining it.

Consider reading Learning Perl. It's a good read, and may be helpful to you.


Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://968329]
and the universe expands...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (5)
As of 2018-06-19 20:57 GMT
Find Nodes?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?

    Results (114 votes). Check out past polls.