| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Perl has had an undocumented macro isALNUMC() for a long time. I want
to document it, but the name is very obscure. Neither Yves nor I are
sure what it is. My best guess is "C's alnum". It corresponds to
/[[:alnum:]]/, and so its best name would be isALNUM(). But that is the
name long given to what matches \w. A new synonym, isWORDCHAR(), has
been in place for several releases for that, but the old isALNUM()
should remain for backwards compatibility.
I don't think that the name isALNUMC() should be published, as it is too
close to isALNUM(). I finally came to the conclusion that
isALPHANUMERIC() is the best name; it describes its purpose clearly; the
disadvantage is its long length. I doubt that it will get much use, but
we need something, I think, that we can publish to accomplish this
functionality.
This commit also converts core uses of isALNUMC to isALPHANUMERIC. (I
intended to that separately, but made a mistake in rebasing, and
combined the two patches; and it seemed like not a big enough problem to
separate them out again.)
|
|
|
|
|
|
|
| |
This finishes the removal of register declarations started by
eb578fdb5569b91c28466a4d1939e381ff6ceaf4. It neglected the ones in
function parameter declarations, and didn't include things in dist, ext,
and lib, which this does include
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This removes most register declarations in C code (and accompanying
documentation) in the Perl core. Retained are those in the ext
directory, Configure, and those that are associated with assembly
language.
See:
http://stackoverflow.com/questions/314994/whats-a-good-example-of-register-variable-usage-in-c
which says, in part:
There is no good example of register usage when using modern compilers
(read: last 10+ years) because it almost never does any good and can do
some bad. When you use register, you are telling the compiler "I know
how to optimize my code better than you do" which is almost never the
case. One of three things can happen when you use register:
The compiler ignores it, this is most likely. In this case the only
harm is that you cannot take the address of the variable in the
code.
The compiler honors your request and as a result the code runs slower.
The compiler honors your request and the code runs faster, this is the least likely scenario.
Even if one compiler produces better code when you use register, there
is no reason to believe another will do the same. If you have some
critical code that the compiler is not optimizing well enough your best
bet is probably to use assembler for that part anyway but of course do
the appropriate profiling to verify the generated code is really a
problem first.
|
|
|
|
|
| |
Replace combinations of macro calls with single ones that mean the same
thing.
|
|
|
|
|
|
|
| |
While I was doing the $[ thing, I discovered a bug in a2p's handling of
the match() operator. It uses a comma operator, which has unintended
behaviour in list context (e.g., in a print statement). It also returns
empty string for a non-match, rather than the required 0.
|
| |
|
|
|
|
|
| |
Fixes #68840 reported by Guglielmo Bondioni, where a2p incorrectly
translated sub(/foo/,"bar/baz") into s/foo/bar/baz/.
|
|
|
|
|
|
| |
From: "Jan Dubois" <jand@activestate.com>
Message-ID: <0cca01c84680$7afc9170$70f5b450$@com>
p4raw-id: //depot/perl@32721
|
|
|
|
|
|
| |
From: "Robin Barker" <Robin.Barker@npl.co.uk>
Message-ID: <46A0F33545E63740BC7563DE59CA9C6D09399C@exchsvr2.npl.ad.local>
p4raw-id: //depot/perl@32690
|
|
|
|
|
| |
Message-ID: <20051104211355.GB12651@petdance.com>
p4raw-id: //depot/perl@26033
|
|
|
|
|
|
|
| |
Message-ID: <20050911094314.GA15155@londo.c47.org>
and remove the check_byacc target from the x2p makefile
p4raw-id: //depot/perl@25534
|
|
|
|
|
|
| |
A C++ compiler produces lots of warnings that are probably valid
concerns to investigate.
p4raw-id: //depot/perl@24170
|
|
|
|
|
|
|
| |
(Lots of Perl 5 source code archaeology was involved.)
Larry didn't make strangled noises when I showed him
the patch, either :-)
p4raw-id: //depot/perl@19242
|
|
|
| |
p4raw-id: //depot/perl@18807
|
|
|
| |
p4raw-id: //depot/perl@18801
|
|
|
| |
p4raw-id: //depot/perl@16076
|
|
|
|
|
|
| |
From: "H.Merijn Brand" <h.m.brand@hccnet.nl>
Message-Id: <20020228173120.6A15.H.M.BRAND@hccnet.nl>
p4raw-id: //depot/perl@14921
|
|
|
| |
p4raw-id: //depot/perl@14391
|
|
|
|
|
| |
Message-Id: <1065978076.20010824221042@tesla.rcub.bg.ac.yu>
p4raw-id: //depot/perl@11744
|
|
|
| |
p4raw-id: //depot/perl@10418
|
|
|
| |
p4raw-id: //depot/perl@10335
|
|
|
| |
p4raw-id: //depot/perl@8289
|
|
|
| |
p4raw-id: //depot/perl@4462
|
|
|
| |
p4raw-id: //depot/perl@3518
|
|
|
| |
p4raw-id: //depot/perl@3436
|
|
|
|
|
| |
Message-Id: <19981030192423.27276.qmail@plover.com>
p4raw-id: //depot/perl@2151
|
|
|
|
|
| |
with gcc -x c++.
p4raw-id: //depot/ansiperl@196
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CORE LANGUAGE CHANGES
Subject: Strictly follow lexical context of C<eval ''> and nested subs
From: Chip Salzenberg <chip@perl.com>
Files: op.c
Subject: Make ::SUPER and UNIVERSAL work together
From: Chip Salzenberg <chip@perl.com>
Files: gv.c pod/perlguts.pod
CORE PORTABILITY
Subject: OS/2 patches
Date: Wed, 5 Mar 1997 22:08:43 -0500 (EST)
From: Ilya Zakharevich <ilya@math.ohio-state.edu>
Files: hints/os2.sh lib/ExtUtils/MakeMaker.pm t/op/taint.t
Msg-ID: 199703060308.WAA22211@monk.mps.ohio-state.edu
(applied based on p5p patch as commit eda4d5189d403b15f244b4696a710fb91d15053e)
Subject: VMS patches
Date: Wed, 05 Mar 1997 23:10:24 -0500 (EST)
From: Charles Bailey <bailey@HMIVAX.HUMGEN.UPENN.EDU>
Files: lib/ExtUtils/MM_VMS.pm lib/ExtUtils/Manifest.pm perlsdio.h t/op/runlevel.t t/op/taint.t vms/descrip.mms vms/perly_c.vms vms/sockadapt.c vms/sockadapt.h vms/vms_yfix.pl
private-msgid: 01IG5SQE4A6U00661G@hmivax.humgen.upenn.edu
DOCUMENTATION
Subject: Add taint checks and srand to perldelta
Date: Sun, 2 Mar 1997 11:56:08 -0800 (PST)
From: Tom Phoenix <rootbeer@teleport.com>
Files: pod/perldelta.pod
Msg-ID: Pine.GSO.3.95q.970302115355.23058D-100000@kelly.teleport.com
(applied based on p5p patch as commit b28e0bc0aa3232e18d1bacb3efcbfb755ad100e0)
Subject: Don't call FileHandle 'deprecated'
From: Chip Salzenberg <chip@perl.com>
Files: pod/perldelta.pod
Subject: Improve sample module header
Date: Sat, 01 Mar 1997 10:32:31 -0700
From: Tom Christiansen <tchrist@jhereg.perl.com>
Files: pod/perlmod.pod
Msg-ID: 199703011732.KAA14693@jhereg.perl.com
(applied based on p5p patch as commit 3e1e15658152387f41e00ded4796cede4e1e10d3)
Subject: Update list of CPAN sites
Date: Sun, 2 Mar 1997 16:54:22 +0200 (EET)
From: Jarkko Hietaniemi <jhi@iki.fi>
Files: pod/perlmod.pod
Msg-ID: 199703021454.QAA07446@alpha.hut.fi
(applied based on p5p patch as commit 9423903e60e6c92c1893f5f4cab2476f403f8a4b)
Subject: Enhance description of 'server error'
Date: Tue, 4 Feb 1997 21:03:23 +0200 (EET)
From: Jarkko Hietaniemi <jhi@cc.hut.fi>
Files: pod/perldiag.pod
private-msgid: 199702041903.VAA16070@alpha.hut.fi
Subject: Regularize format of E-Mail addresses in *.pod
From: Chip Salzenberg <chip@perl.com>
Files: pod/*.pod
LIBRARY AND EXTENSIONS
Subject: Use IV instead of double for tms structure members
From: Chip Salzenberg <chip@perl.com>
Files: ext/POSIX/POSIX.xs
OTHER CORE CHANGES
Subject: Make sure $^X is tainted when ARG_ZERO_IS_SCRIPT
From: Chip Salzenberg <chip@perl.com>
Files: toke.c
Subject: Clarify '-T too late' error
From: Chip Salzenberg <chip@perl.com>
Files: perl.c pod/perldiag.pod
Subject: Warn when redefining or undefining a constant sub
From: Chip Salzenberg <chip@perl.com>
Files: pod/perldiag.pod pp.c sv.c
Subject: Don't generate spurious 'not imported' warning
From: Chip Salzenberg <chip@perl.com>
Files: gv.c t/pragma/strict-vars pod/perldiag.pod
Subject: Clarify message re: @host in string
From: Chip Salzenberg <chip@perl.com>
Files: pod/perldiag.pod pod/perltrap.pod toke.c
Subject: Disconnect refs that are targets of pp_readline
From: Chip Salzenberg <chip@perl.com>
Files: pp_hot.c
Subject: Fix typo in test of HvFILL()
From: Chip Salzenberg <chip@perl.com>
Files: op.c
Subject: Allow for pad name array to be shorter than pad array
From: Chip Salzenberg <chip@perl.com>
Files: op.c
Subject: Eliminate format-string type warnings
Date: Mon, 3 Mar 1997 10:15:11 +0100 (MET)
From: Hallvard B Furuseth <h.b.furuseth@usit.uio.no>
Files: doio.c ext/POSIX/POSIX.xs gv.c hints/dec_osf.sh pp.c pp_ctl.c pp_hot.c run.c sv.c x2p/a2py.c
private-msgid: 199703030915.KAA11634@bombur2.uio.no
Subject: Update copyright dates
From: Chip Salzenberg <chip@perl.com>
Files: *.[hc] x2p/*.[hc] win32/EXTERN.h vms/vmsish.h vms/vms.c
TESTS
Subject: Smarter t/op/taint.t
Date: Mon, 3 Mar 1997 10:31:54 -0800 (PST)
From: Tom Phoenix <rootbeer@teleport.com>
Files: t/op/taint.t
private-msgid: Pine.GSO.3.95q.970303103047.24000A-100000@kelly.teleport.com
Subject: Fix taint test for systems without csh
From: Chip Salzenberg <chip@perl.com>
Files: t/op/taint.t
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
fix]
This is my patch patch.1b for perl5.001.
[Actually, that's a lie. This is just a reposting of two of my
patches (removing some byacc dependencies and fixing some set*id
stuff) + one version of the x2p/walk.c emit_split() patch.
I've just usurped the letter 'b' to fit in my patch sequence.
You probably have already applied these as well, but again here they
are all packaged up nice and neatly for storage on ftp sites.]
Here's one possible solution to the byacc problem. Short summary:
make will think your perly.[ch] are out of date because perly.c.diff
has changed. They aren't really out of date, but the ordering of the
timestamps in the distribution fools make. I had put some traps in
perly.fixer to check to make sure that everything got run only if
you ran the same version of byacc (1.8) as Larry, but the traps aren't good
enough: There's a Cygnus version of byacc out there that also calls
itself 1.8 (with a +Cygnus xxx note attached). I don't think I'll
ever be able to reliably detect all mutant byacc's, so the safest
course of action seems to be to never run byacc.
(Yes, the perly.fixer check could be a _lot_ smarter. Volunteers?)
This simple-minded fix just puts in a
perly.c: perly.y
- touch perly.c
perly.h: perly.y
- touch perly.h
to bring perly.[ch] up to date, if needed.
The '-' are in case your source is read-only.
It also does the same trick in x2p/Makefile.SH.
WARNING! Danger! Larry, if you do this, it means you have to
explicitly call
make run_byacc
whenever you change perly.y, perly.c.diff, or
cd x2p; make run_byacc
if you change x2p/a2p.y.
However, it might be worth it. I leave it up to you.
|
|
|
|
| |
[See the Changes file for a list of changes]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
after patches 0a through 0i
Specifically, here's what's included:
Configure
Regenerated with metaconfig patchlevel 50. This changed
a variety of things, mostly related to selecting and changing
the installation prefix.
Handle csh, sed, and byacc no matter what the setting of
d_portable. (This was causing glob problems in patch.0i).
Set d_portable to default to 'y'. It doesn't matter anyway,
but gives people a warm fuzzy feeling.
Remove useless d_group and d_passwd tests.
Add check for <sys/stat.h>.
Improve & generalize AIX version detection.
Consider /opt/man/man1 as a possible place to install man pages.
Be a little more robust about OS version changes when deciding
if the output of uname -a has really changed.
MANIFEST
MANIFEST.new
Added hints/mpeix.sh.
README
Tell users the Configure defaults are probably right.
Makefile.SH
Better detection of whether user has byacc.
Use $(MAKE) instead of make.
U/Loc_sed.U
Works again with d_portable='define'.
U/Myinit.U
Set d_portable=define as default.
U/d_byacc.U
Detect whether user has byacc even if d_portable=define.
U/d_csh.U
Works again with d_portable='define'.
U/d_group.U
Empty file to avoid useless metaconfig test.
U/d_passwd.U
Empty file to avoid useless metaconfig test.
U/dist.patch
This file contains two minor updates to dist3 PL50 that were used
to generage Configure.
U/i_sysstat.U
New test. See if sys/stat.h is available.
config.H
Updated.
config_h.SH
Updated to metaconfig patchlevel 50.
ext/NDBM_File/Makefile.PL
ext/ODBM_File/Makefile.PL
Add -lucb for SVR4 systems.
handy.h
Protect agains g++-2.6.3, which predefines bool. g++ can be
used to compile an extension, but not perl itself. Still, the
extension will #include "perl.h", which eventually gets
"handy.h", which #define's bool. If this happens to you, add
-DHAS_BOOL to your ccflags in your extension, or else ensure that
_G_config.h is #include'd before perl.h. (_G_config.h will define
_G_HAVE_BOOL, if indeed your version of g++ has bool.)
hints/aix.sh
Updated. Handles AIX 3.2.x and 4.1. Comments included!
hints/hpux_9.sh
Updated.
hints/irix_4.sh
Updated. Includes comments for IRIX 4.0.4
hints/linux.sh
Updated. Beginnings of ELF support added, but completely
untested.
hints/mpeix.sh
New hint file.
hints/solaris_2.sh
Useless ccflags="$ccflags" line removed.
hints/svr4.sh
Updated.
installperl
Doesn't use Config anymore (it already reads config.sh
directly. That's probably backwards, but, oh well.
Install perl.exp for AIX.
lib/ExtUtils/MakeMaker.pm
Upgraded from 4.01 to 4.03.
makedepend.SH
Use $MAKE instead of plain make.
Index: op.c
Remove overlapping strcpy().
perl.h
Add test for <sys/stat.h>.
Delete unused VOIDSIG stuff.
Delete unused typedef struct lstring Lstring;
perl_exp.SH
Add safexxxx calls.
pp_sys.c
Delete wayward break in HAS_ALARM section.
proto.h
Change true and false (!) in function prototypes to please
g++-2.6.3, which has true and false built in. (See notes for
handy.h.)
Index: unixish.h
Long-overdue housekeeping.
HAS_GROUP and HAS_PASSWD are always defined.
util.c
Yet another (char*) cast for bcmp.
vms/config.vms
Changed comments to match unixish.h.
writemain.SH
Now correctly handles nested static extensions. Recent
MakeMakers have moved where they get built.
x2p/a2p.h
More definitions that will doubtless cause trouble somewhere
else.
x2p/a2py.c
x2p/walk.c
Remove unprotected char *strchr();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch does the following things:
1. Fix various bonehead errors I introduced in patches a-g.
2. Incorporate MakeMaker changes to bring it up to version 4.01 (mostly).
3. Stick in things I forgot in patches a-g (e.g. AIX).
4. Some minor additional cleanup in x2p/ for even pickier compilers.
5. More hints updates (hpux and next).
6. Include newest dl_hpux.xs.
I didn't have time to
1. Fix the overlapping strcpy() in op.c
2. Restore h2xs to Larry's original design to process <>.
3. take out unnecessary "use Config" in installperl.
4. Add in vms patches.
I forgot to
[If I remembered what i forgot, I wouldn't have forgotten it. :]
I deliberately decided *not* to
1. Touch pod/*
2. deal with overloading
Specifically, here's what's included:
Configure
Regenerated to be sure it's up-to-date.
Makefile.SH
Build extension libraries right into lib/auto/whatever.
Don't set CCCDLFLAGS since we don't use it anyway.
Take care to avoid modifying lib/Config.pm without reason
Visit DynaLoader for `make clean'. (Previously only did
so for `make realclean'.)
@echo "Note that make realclean does not delete config.sh"
Include config.h dependency.
U/i_db.U
config_h.SH
config.H
Remove unwanted quotes around db_hashtype and db_prefixtype.
configpm
Allow specification of alternate name for lib/Config.pm,
so the makefile mv-if-diff trick saves needless re-making.
ext/DynaLoader/DynaLoader.pm
Updated warning messages and comments.
ext/DynaLoader/dl_hpux.xs
Updated to version 2.1. Now uses bootstrap files.
ext/util/make_ext
Explicitly use #!/bin/sh to start it up. This is useful
for testing make_ext.
Improve & simplify Nested::Extension::Processing.
More robust handling of `make clean'.
hints/hpux_9.sh
Support both the bundled and unbundled compilers.
hints/next_3_2.sh
Back to using -posix rather than POSIX_SOURCE. And that only
for ext/POSIX/POSIX.xs.
installperl
Special ranlib treatment for NeXT, which gets confused about
timestamps in libraries, even when you just copy the library.
Supply missing '$' in samepath() function.
lib/AutoSplit.pm
New parameters.
lib/ExtUtils/MakeMaker.pm
Upgraded from 3.8 to 4.01.
lib/ExtUtils/xsubpp
Documentation changed from man to pod.
lib/Getopt/Long.pm
Avoid typo warning.
Drop unused $optx.
lib/Text/Tabs.pm
Fix package name.
makedepend.SH
Explicitly start with $startsh.
Catch cpp that prints # <stdin> instead of line numbers.
perl.h
Fix bonehead mistake that ended up calling my_fmod even if
not needed.
perl_exp.SH
also add symbols from interp.sym
proto.h
Delete 2 redundant prototypes (newBINOP and newUNOP).
util.c
Add (char *) casts to unsigned char args to bcmp.
x2p/a2p.h
Rearrange order of <string?.h> and bcopy & bzero stuff.
Change a few function prototypes to void, to reflect actual
usage.
x2p/a2py.c
Change a few function types to void, to reflect actual usage.
x2p/handy.h
Make *alloc declarations match those in x2p/util.c.
x2p/util.c
Make *alloc declarations match those in x2p/handy.h.
x2p/walk.c
Add a (Size_t) cast for comparison of 1 to the result of strlen().
Thanks to all who's work is included here. Little of it is mine.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch fixes various non-broken things in the x2p/ directory.
Mostly, I've supplied function prototypes to satisfy particularly
picky compilers.
I've also updated Makefile.SH to know that the byacc-generated a2p.c
is now included with the distribution so that we no longer need to go
looking for yacc/bison/byacc and deal with various library issues or
command line options to support those various compiler compilers.
I've included a2p.c generated by byacc-1.9. Larry, feel free to
use your own from byacc-1.8 instead.
|
|
|
|
|
|
|
|
|
|
|
| |
[editor's note: this commit combines approximate 4 months of furious
releases of Andy Dougherty and Larry Wall - see pod/perlhist.pod for
details. Andy notes that;
Alas neither my "Irwin AccuTrack" nor my DC 600A quarter-inch cartridge
backup tapes from that era seem to be readable anymore. I guess 13 years
exceeds the shelf life for that backup technology :-(.
]
|
|
|
|
| |
[editor's note: from history.perl.org. The sparc executables
originally included in the distribution are not in this commit.]
|
|
|
|
| |
See patch #20.
|
|
|
|
| |
See patch #11.
|
|
|
|
| |
See patch #4.
|
|
|
|
| |
So far, 4.0 is still a beta test version. For the last production
version, look in pub/perl.3.0/kits@44.
|
|
|
|
| |
See patch #29.
|
|
|
|
| |
See patch #19.
|
|
|
|
| |
See patch #9.
|
|
|
|
| |
See patch 7.
|
|
|
|
| |
See patch 5.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A few of the new features: (18 Oct)
* Perl can now handle binary data correctly and has functions to pack and unpack binary structures into arrays or lists. You can now do arbitrary ioctl functions.
* You can now pass things to subroutines by reference.
* Debugger enhancements.
* An array or associative array may now appear in a local() list.
* Array values may now be interpolated into strings.
* Subroutine names are now distinguished by prefixing with &. You can call subroutines without using do, and without passing any argument list at all.
* You can use the new -u switch to cause perl to dump core so that you can run undump and produce a binary executable image. Alternately you can use the "dump" operator after initializing any variables and such.
* You can now chop lists.
* Perl now uses /bin/csh to do filename globbing, if available. This means that filenames with spaces or other strangenesses work right.
* New functions: mkdir and rmdir, getppid, getpgrp and setpgrp, getpriority and setpriority, chroot, ioctl and fcntl, flock, readlink, lstat, rindex, pack and unpack, read, warn, dbmopen and dbmclose, dump, reverse, defined, undef.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some of the enhancements from Perl1 included:
* New regexp routines derived from Henry Spencer's.
o Support for /(foo|bar)/.
o Support for /(foo)*/ and /(foo)+/.
o \s for whitespace, \S for non-, \d for digit, \D nondigit
* Local variables in blocks, subroutines and evals.
* Recursive subroutine calls are now supported.
* Array values may now be interpolated into lists: unlink 'foo', 'bar', @trashcan, 'tmp';
* File globbing.
* Use of <> in array contexts returns the whole file or glob list.
* New iterator for normal arrays, foreach, that allows both read and write.
* Ability to open pipe to a forked off script for secure pipes in setuid scripts.
* File inclusion via do 'foo.pl';
* More file tests, including -t to see if, for instance, stdin is a terminal. File tests now behave in a more correct manner. You can do file tests on filehandles as well as filenames. The special filetests -T and -B test a file to see if it's text or binary.
* An eof can now be used on each file of the <> input for such purposes as resetting the line numbers or appending to each file of an inplace edit.
* Assignments can now function as lvalues, so you can say things like ($HOST = $host) =~ tr/a-z/A-Z/; ($obj = $src) =~ s/\.c$/.o/;
* You can now do certain file operations with a variable which holds the name of a filehandle, e.g. open(++$incl,$includefilename); $foo = <$incl>;
* Warnings are now available (with -w) on use of uninitialized variables and on identifiers that are mentioned only once, and on reference to various undefined things.
* There is now a wait operator.
* There is now a sort operator.
* The manual is now not lying when it says that perl is generally faster than sed. I hope.
|
|
|
|
|
| |
The code a2p creates for the 'for (a in b)' construct ends
up assigning the wrong value to the key variable.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
right on input
Awk ignores leading whitespace on split. Perl by default does not.
The a2p translator couldn't handle this. The fix is partly to a2p
and partly to perl. Perl now has a way to specify to split to
ignore leading white space as awk does. A2p now takes advantage of
that.
I also threw in an optimization that let's runtime patterns
compile just once if they are known to be constant, so that
split(' ') doesn't compile the pattern every time.
|