in reply to use of $*

Not even deprecated anymore. I believe current Perl has removed it. As of 5.20 (possibly earlier) if you use it:

perl -E '$*=1;' $* is no longer supported at -e line 1.

If you want the full explanation of what it used to do, look at an older version of the documentation. 5.8.9 ought to do, and it's available on perldoc.perl.org: http://perldoc.perl.org/5.8.9/perlvar.html:

Set to a non-zero integer value to do multi-line matching within a string, 0 (or undefined) to tell Perl that it can assume that strings contain a single line, for the purpose of optimizing pattern matches. Pattern matches on strings containing multiple newlines can produce confusing results when $* is 0 or undefined. Default is undefined. (Mnemonic: * matches multiple things.) This variable influences the interpretation of only ^ and $ . A literal newline can be searched for even when $* == 0 .


Dave

Replies are listed 'Best First'.
Re^2: use of $*
by Laurent_R (Canon) on Aug 01, 2014 at 18:49 UTC
    Apparently already unsupported in Perl 5.14:
    $ perl -E '$*=1;' $* is no longer supported at -e line 1. $ perl -v This is perl 5, version 14, subversion 4 (v5.14.4) built for cygwin-th +read-multi (with 7 registered patches, see perl -V for more detail) Copyright 1987-2013, Larry Wall Perl may be copied only under the terms of either the Artistic License + or the GNU General Public License, which may be found in the Perl 5 source ki +t. Complete documentation for Perl, including FAQ lists, should be found +on this system using "man perl" or "perldoc perl". If you have access to + the Internet, point your browser at http://www.perl.org/, the Perl Home Pa +ge.