diff options
author | Nick Ing-Simmons <nik@tiuk.ti.com> | 2002-01-05 12:00:48 +0000 |
---|---|---|
committer | Nick Ing-Simmons <nik@tiuk.ti.com> | 2002-01-05 12:00:48 +0000 |
commit | 49b405575f2a73b080d1723eba86035e5d5e327f (patch) | |
tree | 0084add941aa08e1cffed53c86da4bd72478ae21 | |
parent | f2c71312431d5f995ef11f76d09bdfd93e2c3e1d (diff) | |
parent | 591166816e29d06350e6ec8041e206c1afa73419 (diff) | |
download | perl-49b405575f2a73b080d1723eba86035e5d5e327f.tar.gz |
Raw integrate of mainline - op.c looks dodgy.
p4raw-id: //depot/perlio@14087
-rw-r--r-- | AUTHORS | 29 | ||||
-rw-r--r-- | Changes | 142 | ||||
-rw-r--r-- | MANIFEST | 4 | ||||
-rw-r--r-- | NetWare/t/NWScripts.pl | 2 | ||||
-rw-r--r-- | XSUB.h | 6 | ||||
-rw-r--r-- | av.c | 4 | ||||
-rw-r--r-- | av.h | 4 | ||||
-rw-r--r-- | cop.h | 4 | ||||
-rw-r--r-- | cv.h | 4 | ||||
-rw-r--r-- | doio.c | 2 | ||||
-rw-r--r-- | embed.fnc | 3 | ||||
-rw-r--r-- | embed.h | 4 | ||||
-rw-r--r-- | ext/Cwd/t/cwd.t | 8 | ||||
-rw-r--r-- | ext/Devel/PPPort/Makefile.PL | 13 | ||||
-rw-r--r-- | ext/IO/IO.xs | 7 | ||||
-rw-r--r-- | ext/Time/HiRes/HiRes.t | 16 | ||||
-rw-r--r-- | ext/threads/shared/shared.pm | 4 | ||||
-rw-r--r-- | gv.c | 4 | ||||
-rw-r--r-- | gv.h | 2 | ||||
-rw-r--r-- | handy.h | 14 | ||||
-rw-r--r-- | hv.c | 6 | ||||
-rw-r--r-- | hv.h | 6 | ||||
-rw-r--r-- | intrpvar.h | 2 | ||||
-rw-r--r-- | lib/Carp.t | 15 | ||||
-rw-r--r-- | lib/Carp/Heavy.pm | 1 | ||||
-rw-r--r-- | lib/ExtUtils/MM_Unix.pm | 10 | ||||
-rw-r--r-- | lib/File/Compare.pm | 5 | ||||
-rw-r--r-- | lib/File/Find.pm | 2 | ||||
-rw-r--r-- | lib/File/Spec.pm | 2 | ||||
-rw-r--r-- | lib/File/Spec/NW5.pm | 48 | ||||
-rw-r--r-- | lib/Pod/Functions.pm | 82 | ||||
-rw-r--r-- | lib/Pod/t/Functions.t | 158 | ||||
-rw-r--r-- | lib/unicore/Is/SpacePerl.pl | 1 | ||||
-rw-r--r-- | lib/unicore/mktables | 4 | ||||
-rw-r--r-- | mg.c | 4 | ||||
-rw-r--r-- | numeric.c | 4 | ||||
-rw-r--r-- | op.c | 19 | ||||
-rw-r--r-- | op.h | 2 | ||||
-rw-r--r-- | patchlevel.h | 2 | ||||
-rw-r--r-- | perl.c | 15 | ||||
-rw-r--r-- | pod/perldelta.pod | 2 | ||||
-rw-r--r-- | pod/perldiag.pod | 19 | ||||
-rw-r--r-- | pod/perlfaq.pod | 9 | ||||
-rw-r--r-- | pod/perlfaq1.pod | 7 | ||||
-rw-r--r-- | pod/perlfaq2.pod | 7 | ||||
-rw-r--r-- | pod/perlfaq3.pod | 25 | ||||
-rw-r--r-- | pod/perlfaq4.pod | 16 | ||||
-rw-r--r-- | pod/perlfaq5.pod | 6 | ||||
-rw-r--r-- | pod/perlfaq6.pod | 2 | ||||
-rw-r--r-- | pod/perlfaq7.pod | 2 | ||||
-rw-r--r-- | pod/perlfaq8.pod | 7 | ||||
-rw-r--r-- | pod/perlfunc.pod | 4 | ||||
-rw-r--r-- | pod/perlhack.pod | 9 | ||||
-rw-r--r-- | pod/perllocale.pod | 4 | ||||
-rw-r--r-- | pod/perlmodlib.PL | 3 | ||||
-rw-r--r-- | pod/perlmodlib.pod | 159 | ||||
-rw-r--r-- | pod/perlre.pod | 22 | ||||
-rw-r--r-- | pod/perlretut.pod | 2 | ||||
-rw-r--r-- | pod/perlrun.pod | 3 | ||||
-rw-r--r-- | pp.c | 6 | ||||
-rw-r--r-- | pp.h | 2 | ||||
-rw-r--r-- | pp_sort.c | 2 | ||||
-rw-r--r-- | proto.h | 4 | ||||
-rw-r--r-- | regcomp.c | 11 | ||||
-rw-r--r-- | regexec.c | 18 | ||||
-rw-r--r-- | scope.h | 2 | ||||
-rw-r--r-- | sharedsv.c | 2 | ||||
-rw-r--r-- | sv.c | 4 | ||||
-rw-r--r-- | sv.h | 8 | ||||
-rwxr-xr-x | t/comp/proto.t | 19 | ||||
-rw-r--r-- | t/lib/warnings/toke | 19 | ||||
-rwxr-xr-x | t/op/pat.t | 43 | ||||
-rwxr-xr-x | t/op/stat.t | 6 | ||||
-rw-r--r-- | t/op/winsystem.t (renamed from t/op/system.t) | 0 | ||||
-rw-r--r-- | thrdvar.h | 4 | ||||
-rw-r--r-- | toke.c | 4 | ||||
-rw-r--r-- | universal.c | 2 | ||||
-rw-r--r-- | utf8.c | 4 | ||||
-rw-r--r-- | util.c | 20 |
79 files changed, 812 insertions, 340 deletions
@@ -40,9 +40,10 @@ Andrew Bettison <andrewb@zip.com.au> Andrew Cohen <cohen@andy.bu.edu> andrew deryabin <djsf@technarchy.ru> Andrew M. Langmead <aml@world.std.com> -Andrew Pimlott <pimlott@abel.math.harvard.edu> +Andrew Pimlott <pimlott@idiomtech.com> Andrew Vignaux <ajv@nz.sangacorp.com> Andrew Wilcox <awilcox@maine.com> +Andy Busseu <andybussey@yahoo.co.uk> Andy Dougherty <doughera@lafayette.edu> Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> Anthony David <adavid@netinfo.com.au> @@ -53,6 +54,8 @@ Autrijus Tang <autrijus@autrijus.org> Barrie Slaymaker <barries@slaysys.com> Barry Friedman Ben Tilly <ben_tilly@hotmail.com> +Benjamin Goldberg <goldbb2@earthlink.net> +Benjamin Holzman <bah@ecnvantage.com> Benjamin Low <b.d.low@unsw.edu.au> Benjamin Stuhl <sho_pi@hotmail.com> Benjamin Sugars <bsugars@canoe.ca> @@ -61,6 +64,7 @@ Bill Campbell <bill@celestial.com> Bill Glicker <billg@burrelles.com> Billy Constantine <wdconsta@cs.adelaide.edu.au> Blair Zajac <blair@orcaware.com> +Bob Dalgleish <Robert.Dalgleish@sk.sympatico.ca> Boyd Gerber <gerberb@zenez.com> Brad Appleton <bradapp@enteract.com> Brad Howerter <bhower@wgc.woodward.com> @@ -94,6 +98,7 @@ Chaim Frenkel <chaimf@pobox.com> Charles Bailey <bailey@newman.upenn.edu> Charles F. Randall <crandall@free.click-n-call.com> Charles Lane <lane@DUPHY4.Physics.Drexel.Edu> +Charles Randall <cfriv@yahoo.com> Charles Wilson <cwilson@ece.gatech.edu> Chip Salzenberg <chip@pobox.com> Chris Bongaarts <cab@tc.umn.edu> @@ -136,7 +141,9 @@ Darrell Schiebel <drs@nrao.edu> Darren/Torin/Who Ever... <torin@daft.com> Dave Bianchi Dave Hartnoll <Dave_Hartnoll@3b2.com> +Dave Liney <dave.liney@gbr.conoco.com> Dave Nelson <David.Nelson@bellcow.com> +Dave Rolsky <autarch@urth.org> Dave Schweisguth <dcs@neutron.chem.yale.edu> David Billinghurst <David.Billinghurst@riotinto.com.au> David Campbell @@ -159,6 +166,7 @@ David Starks-Browning <dstarks@rc.tudelft.nl> David Sundstrom <sunds@asictest.sc.ti.com> Davin Milun <milun@cs.Buffalo.EDU> Dean Roehrich <roehrich@cray.com> +deekoo <deekoo@tentacle.net> Dennis Marsa <dennism@cyrix.com> dive <dive@ender.com> dLux <dlux@spam.sch.bme.hu> @@ -245,6 +253,7 @@ Hubert Feyrer <hubert.feyrer@informatik.fh-regensburg.de> Hugo van der Sanden <hv@crypt0.demon.co.uk> Hunter Kelly <retnuh@zule.pixar.com> Huw Rogers <count0@gremlin.straylight.co.jp> +I. N. Golubev <gin@mo.msk.ru> Ian Maloney <ian.malonet@ubs.com> Ian Phillipps <Ian.Phillipps@iname.com> Ignasi Roca <ignasi.roca@fujitsu.siemens.es> @@ -315,7 +324,7 @@ John Borwick <jhborwic@unity.ncsu.edu> John Cerney <j-cerney1@ti.com> John D Groenveld <groenvel@cse.psu.edu> John Hasstedt <John.Hasstedt@sunysb.edu> -John Holdsworth <coldwvae@bigfoot.com> +John Holdsworth <coldwave@bigfoot.com> John Hughes <john@AtlanTech.COM> John Kristian <jmk2001@engineer.com> John L. Allen <allen@grumman.com> @@ -441,11 +450,13 @@ Michael Engel <engel@nms1.cc.huji.ac.il> Michael G Schwern <schwern@pobox.com> Michael H. Moran <mhm@austin.ibm.com> Michael Mahan <mahanm@nextwork.rose-hulman.edu> +Michael Somos <somos@grail.cba.csuohio.edu> Michael Stevens <mstevens@globnix.org> Michele Sardo Mik Firestone <fireston@lexmark.com> Mike <mike808@users.sourceforge.net> Mike Fletcher <fletch@phydeaux.org> +Mike Giroux <mgiroux@bear.com> Mike Hopkirk <hops@sco.com> Mike Mestnik <MMestnik@rustconsulting.com> Mike Rogers @@ -453,7 +464,6 @@ Mike Schilli <m@perlmeister.com> Mike Stok <mike@stok.co.uk> Mike W Ellwood <mwe@rl.ac.uk> Mikhail Zabaluev <mhz@alt-linux.org> -Milton Hankins <webtools@uewrhp03.msd.ray.com> Milton L. Hankins <mlh@swl.msd.ray.com> Murray Nesbitt <murray@nesbitt.ca> Nathan Kurz <nate@valleytel.net> @@ -466,7 +476,7 @@ Nick Gianniotis Nick Ing-Simmons <nick@ing-simmons.net> Nikola Knezevic <indy@tesla.rcub.bg.ac.yu> Norbert Pueschel <pueschel@imsdd.meb.uni-bonn.de> -Norton T. Allen <nort@qnx.com> +Norton T. Allen <allen@huarp.harvard.edu> Olaf Flebbe <o.flebbe@science-computing.de> Olaf Titz <olaf@bigred.inka.de> Ollivier Robert <roberto@keltia.freenix.fr> @@ -479,7 +489,8 @@ Paul Green <Paul_Green@stratus.com> Paul Hoffman <phoffman@proper.com> Paul Holser <Paul.Holser.pholser@nortelnetworks.com> Paul Johnson <paul@pjcj.net> -Paul Marquess <Paul.Marquess@btinternet.com> +Paul Lindner <lindner@inuus.com> +Paul Marquess <paul_marquess@yahoo.co.uk> Paul Moore <Paul.Moore@uk.origin-it.com> Paul Rogers <Paul.Rogers@Central.Sun.COM> Paul Saab <ps@yahoo-inc.com> @@ -491,7 +502,7 @@ Peter Gordon <peter@valor.com> Peter Haworth <pmh@edison.ioppublishing.com> Peter J. Farley III <pjfarley@banet.net> Peter Jaspers-Fayer -Peter Prymmer <pvhp@forte.com> +Peter Prymmer <pvhp@best.com> Peter Scott <Peter@PSDT.com> Peter Wolfe <wolfe@teloseng.com> Peter van Heusden <pvh@junior.uwc.ac.za> @@ -520,6 +531,7 @@ Rex Dieter <rdieter@math.unl.edu> Rich Morin <rdm@cfcl.com> Rich Salz <rsalz@bbn.com> Richard A. Wells <Rwells@uhs.harvard.edu> +Richard Clamp <richardc@unixbeard.net> Richard Foley <Richard.Foley@m.dasa.de> Richard L. England <richard_england@mentorg.com> Richard L. Maus, Jr. <rmaus@monmouth.com> @@ -547,19 +559,22 @@ Russell Mosemann Ryan Herbert <rherbert@sycamorehq.com> SADAHIRO Tomoyuki <BQW10602@nifty.com> SAKAI Kiyotaka <ksakai@netwk.ntt-at.co.jp> +Sam Tregar <sam@tregar.com> Samuli Kärkkäinen <skarkkai@woods.iki.fi> Scott Bronson <bronson@rinspin.com> Scott Gifford <sgifford@tir.com> Scott Henry <scotth@sgi.com> Scott L. Miller <Scott.L.Miller@Compaq.com> Sean Dague <sean@dague.net> +Sean M. Burke <sburke@cpan.org> Sean Robinson <robinson_s@sc.maricopa.edu> Sean Sheedy <seans@ncube.com> Sebastien Barre <Sebastien.Barre@utc.fr> Shigeya Suzuki <shigeya@foretune.co.jp> Shimpei Yamashita <shimpei@socrates.patnet.caltech.edu> Shishir Gundavaram <shishir@ruby.ora.com> -Simon Cozens <simon@cozens.net> +Simon Cozens <simon@netthink.co.uk> +Simon Glover <scog@roe.ac.uk> Simon Leinen Simon Parsons <S.Parsons@ftel.co.uk> Slaven Rezic <eserte@cs.tu-berlin.de> @@ -31,6 +31,148 @@ or any other branch. Version v5.7.2 Development release working toward v5.8 -------------- ____________________________________________________________________________ +[ 14041] By: jhi on 2002/01/03 15:57:42 + Log: Missed the =head1 additions. + Branch: perl + ! XSUB.h av.c av.h cop.h cv.h doio.c gv.c gv.h handy.h hv.h + ! intrpvar.h mg.c numeric.c op.c op.h perl.c pp.h pp_sort.c + ! scope.h sharedsv.c sv.c sv.h thrdvar.h universal.c utf8.c + ! util.c +____________________________________________________________________________ +[ 14040] By: jhi on 2002/01/03 15:05:06 + Log: Subject: [PATCH lib/Carp/Heavy.pm lib/Carp.t] obscure warning from Carp::Heavy + From: Robin Barker <rmb1@cise.npl.co.uk> + Date: Thu, 3 Jan 2002 15:26:20 GMT + Message-Id: <200201031526.PAA06095@tempest.npl.co.uk> + Branch: perl + ! lib/Carp.t lib/Carp/Heavy.pm +____________________________________________________________________________ +[ 14039] By: jhi on 2002/01/03 15:02:12 + Log: Subject: [PATCH hv.c] + From: Robin Barker <rmb1@cise.npl.co.uk> + Date: Thu, 3 Jan 2002 14:49:06 GMT + Message-Id: <200201031449.OAA26137@tempest.npl.co.uk> + + -Wformat check. + Branch: perl + ! hv.c +____________________________________________________________________________ +[ 14038] By: jhi on 2002/01/03 15:01:09 + Log: NetWare tweaks from Ananth Kesari. + Branch: perl + ! NetWare/t/NWScripts.pl lib/File/Find.pm +____________________________________________________________________________ +[ 14037] By: jhi on 2002/01/03 13:41:38 + Log: Cast. + Branch: perl + ! regexec.c +____________________________________________________________________________ +[ 14036] By: ams on 2002/01/03 12:12:31 + Log: Grammar fix suggested by Gwyn Judd. + Branch: perl + ! pod/perldiag.pod +____________________________________________________________________________ +[ 14033] By: ams on 2002/01/03 08:24:24 + Log: Subject: Not ok 14031: PPPort Makefile.PL + From: andreas.koenig@anima.de (Andreas J. Koenig) + Date: 03 Jan 2002 10:17:46 +0100 + Message-Id: <m3sn9n94jp.fsf@anima.de> + Branch: perl + ! ext/Devel/PPPort/Makefile.PL +____________________________________________________________________________ +[ 14031] By: jhi on 2002/01/03 01:52:04 + Log: Off-by-one is my middle name. + Branch: perl + ! regexec.c +____________________________________________________________________________ +[ 14030] By: ams on 2002/01/02 23:56:37 + Log: Subject: [PATCH @14015] threads::shared disabling + From: Andy Bussey <andybussey@yahoo.co.uk> + Date: Thu, 3 Jan 2002 00:46:58 +0000 (GMT) + Message-Id: <20020103004658.97969.qmail@web21006.mail.yahoo.com> + Branch: perl + + ext/threads/shared/t/no_share.t + ! MANIFEST ext/threads/shared/shared.pm ext/threads/threads.pm +____________________________________________________________________________ +[ 14029] By: jhi on 2002/01/02 23:40:08 + Log: Simon's new perlapi scheme, I hope I got all the pieces. + Branch: perl + + autodoc.pl embed.fnc + ! MANIFEST Makefile.SH embed.pl pod/perlapi.pod +____________________________________________________________________________ +[ 14028] By: jhi on 2002/01/02 23:29:03 + Log: Integrate perlio; more PPPort Makefile source dependence removal + Branch: perl + !> ext/Devel/PPPort/Makefile.PL perl.h +____________________________________________________________________________ +[ 14027] By: ams on 2002/01/02 21:42:50 + Log: Subject: [PATCH perldiag] errors caused by the "my Dog $spot" syntax + From: Rafael Garcia-Suarez <rgarciasuarez@free.fr> + Date: Wed, 2 Jan 2002 23:09:13 +0100 + Message-Id: <20020102230913.A17373@rafael> + Branch: perl + ! pod/perldiag.pod +____________________________________________________________________________ +[ 14026] By: ams on 2002/01/02 21:38:34 + Log: Subject: Re: PATCH: lib/Term/Cap.pm + From: Jonathan Stowe <gellyfish@gellyfish.com> + Date: Wed, 2 Jan 2002 21:50:36 +0000 (GMT) + Message-Id: <Pine.LNX.4.33.0201022144370.6042-100000@orpheus.gellyfish.com> + Branch: perl + ! lib/Term/Cap.pm +____________________________________________________________________________ +[ 14025] By: ams on 2002/01/02 18:34:26 + Log: Subject: [PATCH] Bad prototype detection changed from error to warning + From: Sam Tregar <sam@tregar.com> + Date: Wed, 2 Jan 2002 14:04:26 -0500 (EST) + Message-Id: <Pine.LNX.4.33.0201021400110.15420-200000@localhost.localdomain> + Branch: perl + ! pod/perldiag.pod t/comp/proto.t toke.c +____________________________________________________________________________ +[ 14024] By: ams on 2002/01/02 18:16:12 + Log: Subject: PATCH: lib/Term/Cap.pm + From: Norton Allen <allen@huarp.harvard.edu> + Date: Wed, 2 Jan 2002 14:22:09 -0500 (est) + Message-Id: <200201021922.OAA18505@bottesini.harvard.edu> + Branch: perl + ! lib/Term/Cap.pm +____________________________________________________________________________ +[ 14023] By: ams on 2002/01/02 18:12:31 + Log: Subject: PATCH: lib/Cwd.pm for QNX4 + From: Norton Allen <allen@huarp.harvard.edu> + Date: Wed, 2 Jan 2002 14:19:42 -0500 (est) + Message-Id: <200201021919.OAA18012@bottesini.harvard.edu> + Branch: perl + ! lib/Cwd.pm +____________________________________________________________________________ +[ 14020] By: ams on 2002/01/02 17:06:27 + Log: Fix misplaced application of #14016. + Branch: perl + ! op.c +____________________________________________________________________________ +[ 14019] By: jhi on 2002/01/02 16:51:38 + Log: Integrate perlio; avoid uninit debug_pad. + Branch: perl + !> sv.c +____________________________________________________________________________ +[ 14018] By: jhi on 2002/01/02 16:50:22 + Log: makedepend VOS fix from Paul Green. + Branch: perl + ! makedepend.SH +____________________________________________________________________________ +[ 14016] By: ams on 2002/01/02 15:58:11 + Log: Subject: [PATCH] random crash in B::LISTOP::last + From: "Mattia Barbon" <mbarbon@dsi.unive.it> + Date: Wed, 2 Jan 2002 17:37:28 +0100 + Message-Id: <3C334558.3906.19CB98D@localhost> + Branch: perl + ! op.c +____________________________________________________________________________ +[ 14015] By: jhi on 2002/01/02 15:21:12 + Log: Update Changes. + Branch: perl + ! Changes patchlevel.h +____________________________________________________________________________ [ 14014] By: jhi on 2002/01/02 15:12:57 Log: One more iteration of the ibcmp_utf8() interface, hopefully this is a convergent iteration... @@ -988,7 +988,6 @@ lib/File/Spec/Cygwin.pm portable operations on Cygwin file names lib/File/Spec/Epoc.pm portable operations on EPOC file names lib/File/Spec/Functions.pm Function interface to File::Spec object methods lib/File/Spec/Mac.pm portable operations on Mac file names -lib/File/Spec/NW5.pm portable operations on NetWare file names lib/File/Spec/OS2.pm portable operations on OS2 file names lib/File/Spec/t/Functions.t See if File::Spec::Functions works lib/File/Spec/t/rel2abs2rel.t See if File::Spec->rel2abs/abs2rel works @@ -1212,6 +1211,7 @@ lib/Pod/t/basic.pod podlators test lib/Pod/t/basic.t podlators test lib/Pod/t/basic.txt podlators test lib/Pod/t/man.t podlators test +lib/Pod/t/Functions.t See if Pod::Functions works lib/Pod/t/InputObjects.t See if Pod::InputObjects works lib/Pod/t/latex.t Test for Pod::LaTeX lib/Pod/t/parselink.t podlators test @@ -2303,7 +2303,6 @@ t/op/subst_amp.t See if $&-related substitution works t/op/subst_wamp.t See if substitution works with $& present t/op/sub_lval.t See if lvalue subroutines work t/op/sysio.t See if sysread and syswrite work -t/op/system.t See if system works t/op/system_tests Test runner for system.t t/op/taint.t See if tainting works t/op/tie.t See if tie/untie functions work @@ -2318,6 +2317,7 @@ t/op/utf8decode.t See if UTF-8 decoding works t/op/vec.t See if vectors work t/op/ver.t See if v-strings and the %v format flag work t/op/wantarray.t See if wantarray works +t/op/winsystem.t See if system works in Win* t/op/write.t See if write works (formats work) t/pod/emptycmd.t Test empty pod directives t/pod/emptycmd.xr Expected results for emptycmd.t diff --git a/NetWare/t/NWScripts.pl b/NetWare/t/NWScripts.pl index a2f22a43ef..8ab39296ab 100644 --- a/NetWare/t/NWScripts.pl +++ b/NetWare/t/NWScripts.pl @@ -11,7 +11,7 @@ $DirName = "t"; # These scripts have problems (either abend or hang) as of now (11 May 2001). # So, they are commented out in the corresponding auto scripts, io.pl and lib.pl -@ScriptsNotUsed = ("t/io/argv.t", "t/io/openpid.t", "t/lib/filehandle.t", "t/lib/warnings.t"); +@ScriptsNotUsed = ("t/io/openpid.t", "t/lib/filehandle.t", "t/lib/memoize/t/expire_module_t.t"); opendir(DIR, $DirName); @Dirs = readdir(DIR); @@ -4,6 +4,8 @@ /* first, some documentation for xsubpp-generated items */ /* +=head1 Variables created by C<xsubpp> and C<xsubpp> internal functions + =for apidoc Amn|char*|CLASS Variable which is setup by C<xsubpp> to indicate the class name for a C++ XS constructor. This is always a C<char*>. See C<THIS>. @@ -98,6 +100,8 @@ handled automatically by C<xsubpp>. /* Typically used to return values from XS functions. */ /* +=head1 Stack Manipulation Macros + =for apidoc Am|void|XST_mIV|int pos|IV iv Place an integer into the specified position C<pos> on the stack. The value is stored in a new mortal SV. @@ -147,6 +151,8 @@ Return C<&PL_sv_undef> from an XSUB immediately. Uses C<XST_mUNDEF>. =for apidoc Ams||XSRETURN_EMPTY Return an empty list from an XSUB immediately. +=head1 Variables created by C<xsubpp> and C<xsubpp> internal functions + =for apidoc AmU||newXSproto Used by C<xsubpp> to hook up XSUBs as Perl subs. Adds Perl prototypes to the subs. @@ -12,6 +12,10 @@ * meant that things should remain where they had set them)." --Treebeard */ +/* +=head1 Array Manipulation Functions +*/ + #include "EXTERN.h" #define PERL_IN_AV_C #include "perl.h" @@ -46,9 +46,13 @@ struct xpvav { #define AVf_REUSED 4 /* got undeffed--don't turn old memory into SVs now */ /* +=head1 Handy Values + =for apidoc AmU||Nullav Null AV pointer. +=head1 Array Manipulation Functions + =for apidoc Am|int|AvFILL|AV* av Same as C<av_len()>. Deprecated, use C<av_len()> instead. @@ -388,7 +388,9 @@ struct context { #define CXINC (cxstack_ix < cxstack_max ? ++cxstack_ix : (cxstack_ix = cxinc())) -/* "gimme" values */ +/* +=head1 "Gimme" Values +*/ /* =for apidoc AmU||G_SCALAR @@ -37,9 +37,13 @@ struct xpvcv { }; /* +=head1 Handy Values + =for apidoc AmU||Nullcv Null CV pointer. +=head1 CV Manipulation Functions + =for apidoc Am|HV*|CvSTASH|CV* cv Returns the stash of the CV. @@ -2106,6 +2106,8 @@ Perl_do_shmio(pTHX_ I32 optype, SV **mark, SV **sp) #endif /* SYSV IPC */ /* +=head1 IO Functions + =for apidoc start_glob Function called by C<do_readline> to spawn a glob (or do the glob inside @@ -1304,10 +1304,7 @@ Apd |STRLEN |sv_utf8_upgrade_flags|SV *sv|I32 flags Apd |char* |sv_pvn_force_flags|SV* sv|STRLEN* lp|I32 flags Apd |char* |sv_2pv_flags |SV* sv|STRLEN* lp|I32 flags Ap |char* |my_atof2 |const char *s|NV* value -#if !defined(HAS_SOCKETPAIR) && defined(HAS_SOCKET) Apn |int |my_socketpair |int family|int type|int protocol|int fd[2] -#endif - #if defined(USE_PERLIO) && !defined(USE_SFIO) Ap |int |PerlIO_close |PerlIO * @@ -1203,9 +1203,7 @@ #define sv_pvn_force_flags Perl_sv_pvn_force_flags #define sv_2pv_flags Perl_sv_2pv_flags #define my_atof2 Perl_my_atof2 -#if !defined(HAS_SOCKETPAIR) && defined(HAS_SOCKET) #define my_socketpair Perl_my_socketpair -#endif #if defined(USE_PERLIO) && !defined(USE_SFIO) #define PerlIO_close Perl_PerlIO_close #define PerlIO_fill Perl_PerlIO_fill @@ -2744,9 +2742,7 @@ #define sv_pvn_force_flags(a,b,c) Perl_sv_pvn_force_flags(aTHX_ a,b,c) #define sv_2pv_flags(a,b,c) Perl_sv_2pv_flags(aTHX_ a,b,c) #define my_atof2(a,b) Perl_my_atof2(aTHX_ a,b) -#if !defined(HAS_SOCKETPAIR) && defined(HAS_SOCKET) #define my_socketpair Perl_my_socketpair -#endif #if defined(USE_PERLIO) && !defined(USE_SFIO) #define PerlIO_close(a) Perl_PerlIO_close(aTHX_ a) #define PerlIO_fill(a) Perl_PerlIO_fill(aTHX_ a) diff --git a/ext/Cwd/t/cwd.t b/ext/Cwd/t/cwd.t index b636c6db90..88a1b9477e 100644 --- a/ext/Cwd/t/cwd.t +++ b/ext/Cwd/t/cwd.t @@ -29,11 +29,15 @@ eval { fastcwd }; # Must find an external pwd (or equivalent) command. my $pwd_cmd = - ($^O eq "MSWin32" || $^O eq "NetWare") ? "cd" : (grep { -x && -f } map { "$_/pwd" } - split m/$Config{path_sep}/, $ENV{PATH})[0]; + ($^O eq "MSWin32" || $^O eq "NetWare") ? + "cd" : + (grep { -x && -f } map { "$_/pwd" } + split m/$Config{path_sep}/, $ENV{PATH})[0]; $pwd_cmd = 'SHOW DEFAULT' if $IsVMS; +print "# native pwd = '$pwd_cmd'\n"; + SKIP: { skip "No native pwd command found to test against", 4 unless $pwd_cmd; diff --git a/ext/Devel/PPPort/Makefile.PL b/ext/Devel/PPPort/Makefile.PL index 21aedf3f24..0259a05e5a 100644 --- a/ext/Devel/PPPort/Makefile.PL +++ b/ext/Devel/PPPort/Makefile.PL @@ -1,4 +1,3 @@ - use ExtUtils::MakeMaker; WriteMakefile( @@ -7,19 +6,21 @@ WriteMakefile( VERSION_FROM=> 'PPPort.pm', #PM => {'PPPort.pm' => '$(INST_LIBDIR)/PPPort.pm'}, - OBJECT => 'PPPort$(OBJ_EXT) module2$(OBJ_EXT) module3$(OBJ_EXT)', + C => [qw(module2.c module3.c)], + H => [qw(ppport.h)], + OBJECT => '$(BASEEXT)$(OBJ_EXT) $(O_FILES)', XSPROTOARG => '-noprototypes', 'dist' => { COMPRESS=>"gzip", SUFFIX=>"gz" }, - 'clean' => { FILES => "ppport.h ppport_h"}, + 'clean' => { FILES => qw($(H_FILES))} ); sub MY::postamble { return <<"EOM"; -ppport.h: ppport_h - \$(TOUCH) ppport_h +\$(H_FILES) : ppport_h.PL + \$(PERLRUNINST) ppport_h.PL -PPPort\$(OBJ_EXT) module2\$(OBJ_EXT) module3\$(OBJ_EXT): ppport.h +\$(OBJECT) : \$(H_FILES) EOM } diff --git a/ext/IO/IO.xs b/ext/IO/IO.xs index 9cefe08be5..dc810d68a5 100644 --- a/ext/IO/IO.xs +++ b/ext/IO/IO.xs @@ -26,6 +26,13 @@ #endif #ifdef PerlIO +#ifdef MACOS_TRADITIONAL +#define PERLIO_IS_STDIO 1 +#undef setbuf +#undef setvbuf +#define setvbuf _stdsetvbuf +#define setbuf(f,b) ( __sf_setbuf(f,b) ) +#endif typedef int SysRet; typedef PerlIO * InputStream; typedef PerlIO * OutputStream; diff --git a/ext/Time/HiRes/HiRes.t b/ext/Time/HiRes/HiRes.t index e246d82f62..c09eaa7453 100644 --- a/ext/Time/HiRes/HiRes.t +++ b/ext/Time/HiRes/HiRes.t @@ -128,14 +128,24 @@ else { my $tick = 0; local $SIG{ALRM} = sub { $tick++ }; - my $one = time; $tick = 0; ualarm(10_000); sleep until $tick; - my $two = time; $tick = 0; ualarm(10_000); sleep until $tick; + # This was previously written sleep 3 until $tick; + # But there is a small race condition here: the alarm may go off + # until ($tick) { Here!; sleep } + # In which case the sleep is forever. + # sleeping for 3 seconds will cause the test to fail but it's better than + # infinite hang. [Until someone produces a platform where sleep interferes + # with ualarm, in which case a more sophisticated self destruct will need + # to be written (eg fork, child sleeps for a long time, child kills parent + # if parent doesn't finish first (killing child))] + + my $one = time; $tick = 0; ualarm(10_000); sleep 3 until $tick; + my $two = time; $tick = 0; ualarm(10_000); sleep 3 until $tick; my $three = time; ok 12, $one == $two || $two == $three, "slept too long, $one $two $three"; $tick = 0; ualarm(10_000, 10_000); - sleep until $tick >= 3; + sleep 3 until $tick >= 3; ok 13, 1; ualarm(0); } diff --git a/ext/threads/shared/shared.pm b/ext/threads/shared/shared.pm index 1f2ad9d99c..62cdbdd105 100644 --- a/ext/threads/shared/shared.pm +++ b/ext/threads/shared/shared.pm @@ -211,10 +211,10 @@ in a C<cond_wait> on the locked variable, rather than only one. =head1 NOTES -threads::shared is designed is disable itself silently if threads are +threads::shared is designed to disable itself silently if threads are not available. If you want access to threads, you must C<use threads> before you C<use threads::shared>. threads will emit a warning if you -use it before threads::shared. +use it after threads::shared. =head1 BUGS @@ -16,6 +16,10 @@ * laughed Pippin. */ +/* +=head1 GV Functions +*/ + #include "EXTERN.h" #define PERL_IN_GV_C #include "perl.h" @@ -35,6 +35,8 @@ struct gp { #define GvFLAGS(gv) (GvXPVGV(gv)->xgv_flags) /* +=head1 GV Functions + =for apidoc Am|SV*|GvSV|GV* gv Return the SV from the GV. @@ -21,9 +21,10 @@ #define Null(type) ((type)NULL) /* -=for apidoc AmU||Nullch -Null character pointer. +=head1 Handy Values +=for apidoc AmU||Nullch +Null character pointer. =for apidoc AmU||Nullsv Null SV pointer. @@ -210,6 +211,8 @@ typedef U64TYPE U64; #define Ctl(ch) ((ch) & 037) /* +=head1 Miscellaneous Functions + =for apidoc Am|bool|strNE|char* s1|char* s2 Test two strings to see if they are different. Returns true or false. @@ -283,6 +286,9 @@ C<strncmp>). #endif /* + +=head1 Character classes + =for apidoc Am|bool|isALNUM|char ch Returns a boolean indicating whether the C C<char> is an ASCII alphanumeric character (including underscore) or digit. @@ -515,6 +521,8 @@ typedef U16 line_t; */ /* +=head1 SV Manipulation Functions + =for apidoc Am|SV*|NEWSV|int id|STRLEN len Creates a new SV. A non-zero C<len> parameter indicates the number of bytes of preallocated string space the SV should have. An extra byte for a @@ -522,6 +530,8 @@ tailing NUL is also reserved. (SvPOK is not set for the SV even if string space is allocated.) The reference count for the new SV is set to 1. C<id> is an integer id between 0 and 1299 (used to identify leaks). +=head1 Memory Management + =for apidoc Am|void|New|int id|void* ptr|int nitems|type The XSUB-writer's interface to the C C<malloc> function. @@ -11,6 +11,10 @@ * "I sit beside the fire and think of all that I have seen." --Bilbo */ +/* +=head1 Hash Manipulation Functions +*/ + #include "EXTERN.h" #define PERL_IN_HV_C #include "perl.h" @@ -142,7 +146,7 @@ Perl_hv_notallowed(pTHX_ bool is_utf8, const char *key, I32 klen, if (is_utf8) { SvUTF8_on(sv); } - Perl_croak(aTHX_ "Attempt to access to key '%_' in fixed hash",sv); + Perl_croak(aTHX_ "Attempt to access to key '%"SVf"' in fixed hash",sv); } /* (klen == HEf_SVKEY) is special for MAGICAL hv entries, meaning key slot @@ -63,14 +63,20 @@ struct xpvhv { } STMT_END /* +=head1 Hash Manipulation Functions + =for apidoc AmU||HEf_SVKEY This flag, used in the length slot of hash entries and magic structures, specifies the structure contains an C<SV*> pointer where a C<char*> pointer is to be expected. (For information only--not to be used). +=head1 Handy Values + =for apidoc AmU||Nullhv Null HV pointer. +=head1 Hash Manipulation Functions + =for apidoc Am|char*|HvNAME|HV* stash Returns the package name of a stash. See C<SvSTASH>, C<CvSTASH>. diff --git a/intrpvar.h b/intrpvar.h index c46c8c1a30..3d08143fb6 100644 --- a/intrpvar.h +++ b/intrpvar.h @@ -38,6 +38,8 @@ PERLVAR(Iminus_F, bool) PERLVAR(Idoswitches, bool) /* +=head1 Global Variables + =for apidoc mn|bool|PL_dowarn The C variable which corresponds to Perl's $^W warning variable. diff --git a/lib/Carp.t b/lib/Carp.t index e9dd8cd7f5..2ea98d86d7 100644 --- a/lib/Carp.t +++ b/lib/Carp.t @@ -5,7 +5,7 @@ BEGIN { use Carp qw(carp cluck croak confess); -print "1..8\n"; +print "1..9\n"; print "ok 1\n"; @@ -56,3 +56,16 @@ my $eval = "use Carp::Heavy; return Carp::caller_info(0);"; my %info = eval($eval); print "not " if ($info{sub_name} ne "eval '$eval'"); print "ok 8\n"; + +# test for '...::CARP_NOT used only once' warning from Carp::Heavy +my $warning; +eval { + BEGIN { + $^W = 1; + $SIG{__WARN__} = + sub { if( defined $^S ){ warn $_[0] } else { $warning = $_[0] } } + } + package Z; + BEGIN { eval { Carp::croak() } } +}; +print $warning ? "not ok 9\n#$warning" : "ok 9\n"; diff --git a/lib/Carp/Heavy.pm b/lib/Carp/Heavy.pm index cf108923f4..c3d3c26fa1 100644 --- a/lib/Carp/Heavy.pm +++ b/lib/Carp/Heavy.pm @@ -237,6 +237,7 @@ sub trusts { sub trusts_directly { my $class = shift; no strict 'refs'; + no warnings 'once'; return @{"$class\::CARP_NOT"} ? @{"$class\::CARP_NOT"} : @{"$class\::ISA"}; diff --git a/lib/ExtUtils/MM_Unix.pm b/lib/ExtUtils/MM_Unix.pm index fd03d560dd..6c08d9a2c6 100644 --- a/lib/ExtUtils/MM_Unix.pm +++ b/lib/ExtUtils/MM_Unix.pm @@ -2049,20 +2049,22 @@ usually solves this kind of problem. # Are we building the core? $self->{PERL_CORE} = 0 unless exists $self->{PERL_CORE}; + my $aq = ($^O eq 'VMS' ? '"' : ''); # command-line argument quoter + # How do we run perl? $self->{PERLRUN} = $self->{PERL}; - $self->{PERLRUN} .= ' -I$(PERL_LIB)' if $self->{UNINSTALLED_PERL}; + $self->{PERLRUN} .= " -${aq}I\$(PERL_LIB)$aq" if $self->{UNINSTALLED_PERL}; # How do we run perl when installing libraries? - $self->{PERLRUNINST} .= $self->{PERLRUN}. ' -I$(INST_ARCHLIB) -I$(INST_LIB)'; + $self->{PERLRUNINST} .= $self->{PERLRUN}. " -${aq}I\$(INST_ARCHLIB)$aq -${aq}I\$(INST_LIB)$aq"; # What extra library dirs do we need when running the tests? - $self->{TEST_LIBS} .= ' -I$(INST_ARCHLIB) -I$(INST_LIB)'; + $self->{TEST_LIBS} .= " -${aq}I\$(INST_ARCHLIB)$aq -${aq}I\$(INST_LIB)$aq"; # When building the core, we need to add some helper libs since # perl's @INC won't work (we're not installed yet). foreach my $targ (qw(PERLRUN PERLRUNINST TEST_LIBS)) { - $self->{$targ} .= ' -I$(PERL_ARCHLIB) -I$(PERL_LIB)' + $self->{$targ} .= " -${aq}I\$(PERL_ARCHLIB)$aq -${aq}I\$(PERL_LIB)$aq" if $self->{PERL_CORE}; } } diff --git a/lib/File/Compare.pm b/lib/File/Compare.pm index e1d5e7db91..eba17c3253 100644 --- a/lib/File/Compare.pm +++ b/lib/File/Compare.pm @@ -15,11 +15,6 @@ $VERSION = '1.1003'; $Too_Big = 1024 * 1024 * 2; -sub VERSION { - # Version of File::Compare - return $File::Compare::VERSION; -} - sub compare { croak("Usage: compare( file1, file2 [, buffersize]) ") unless(@_ == 2 || @_ == 3); diff --git a/lib/File/Find.pm b/lib/File/Find.pm index dbc1b78343..41afeb93e2 100644 --- a/lib/File/Find.pm +++ b/lib/File/Find.pm @@ -1137,7 +1137,7 @@ $File::Find::current_dir = File::Spec->curdir || '.'; $File::Find::dont_use_nlink = 1 if $^O eq 'os2' || $^O eq 'dos' || $^O eq 'amigaos' || $^O eq 'MSWin32' || - $^O eq 'cygwin' || $^O eq 'epoc' || $^O eq 'NetWare'; + $^O eq 'cygwin' || $^O eq 'epoc'; # Set dont_use_nlink in your hint file if your system's stat doesn't # report the number of links in a directory as an indication diff --git a/lib/File/Spec.pm b/lib/File/Spec.pm index cf49cf6b67..3ac1060f0c 100644 --- a/lib/File/Spec.pm +++ b/lib/File/Spec.pm @@ -10,7 +10,7 @@ my %module = (MacOS => 'Mac', os2 => 'OS2', VMS => 'VMS', epoc => 'Epoc', - NetWare => 'NW5', + NetWare => 'Win32', # Yes, File::Spec::Win32 works on NetWare. cygwin => 'Cygwin'); diff --git a/lib/File/Spec/NW5.pm b/lib/File/Spec/NW5.pm deleted file mode 100644 index 772a93df56..0000000000 --- a/lib/File/Spec/NW5.pm +++ /dev/null @@ -1,48 +0,0 @@ -package File::Spec::NW5; - -use strict; -use vars qw(@ISA $VERSION); -require File::Spec::Win32; - -$VERSION = '1.0'; - -@ISA = qw(File::Spec::Win32); - -sub catdir { - my $self = shift; - my @args = @_; - for (@args) { - # append a slash to each argument unless it has one there - $_ .= "\\" if $_ eq '' or substr($_,-1) ne "\\"; - } - my $result = $self->canonpath(join('', @args)); - $result; -} - -sub canonpath { - my $self = shift; - my $path = $self->SUPER::canonpath(@_); - $path .= '.' if $path =~ m#\\$#; - return $path; -} - - -1; -__END__ - -=head1 NAME - -File::Spec::NW5 - methods for NetWare file specs - -=head1 SYNOPSIS - - require File::Spec::NW5; # Done internally by File::Spec if needed - -=head1 DESCRIPTION - -See File::Spec::Win32 and File::Spec::Unix for a documentation of the -methods provided there. This package overrides the implementation of -these methods, not the semantics. - -This module is still in beta. NetWare-knowledgeable folks are invited -to offer patches and suggestions. diff --git a/lib/Pod/Functions.pm b/lib/Pod/Functions.pm index 960b847394..7f7e15060a 100644 --- a/lib/Pod/Functions.pm +++ b/lib/Pod/Functions.pm @@ -1,13 +1,75 @@ package Pod::Functions; +use strict; -#:vi:set ts=20 +=head1 NAME -our $VERSION = '1.00'; +Pod::Functions - Group Perl's functions a la perlfunc.pod + +=head1 SYNOPSIS + + use Pod:Functions; + + my @misc_ops = @{ $Kinds{ 'Misc' } }; + my $misc_dsc = $Type_Description{ 'Misc' }; + +or + + perl /path/to/lib/Pod/Functions.pm + +This will print a grouped list of Perl's functions, like the +L<perlfunc/"Perl Functions by Category"> section. + +=head1 DESCRIPTION + +It exports the following variables: + +=over 4 + +=item %Kinds + +This holds a hash-of-lists. Each list contains the functions in the catagory +the key denotes. + +=item %Type + +In this hash each key represents a function and the value is the catagory. +The catagory can be a comma separated list. + +=item %Flavor + +In this hash each key represents a function and the value is a short +description of that function. + +=item %Type_Description + +In this hash each key represents a catagory of functions and the value is +a short description of that catagory. + +=item @Type_Order + +This list of catagories is used to produce the same order as the +L<perlfunc/"Perl Functions by Category"> section. + +=back + +=head1 CHANGES + +1.01 20011229 <abe@ztreet.demon.nl> + fixed some bugs that slipped in after 5.6.1 + added the pod + finished making it strict safe + +1.00 ?? + first numbered version + +=cut + +our $VERSION = '1.01'; require Exporter; -@ISA = qw(Exporter); -@EXPORT = qw(%Kinds %Type %Flavor %Type_Description @Type_Order); +our @ISA = qw(Exporter); +our @EXPORT = qw(%Kinds %Type %Flavor %Type_Description @Type_Order); our(%Kinds, %Type, %Flavor); @@ -65,16 +127,17 @@ while (<DATA>) { $Type{$name} = $type; $Flavor{$name} = $text; for my $t ( split /[,\s]+/, $type ) { - push @{$Kinds{$t}}, $name; + push @{$Kinds{$t}}, $name; } -} +} close DATA; +my( $typedesc, $list ); unless (caller) { foreach my $type ( @Type_Order ) { - my $list = join(", ", sort @{$Kinds{$type}}); - my $typedesc = $Type_Description{$type} . ":"; + $list = join(", ", sort @{$Kinds{$type}}); + $typedesc = $Type_Description{$type} . ":"; write; } } @@ -89,7 +152,7 @@ format = $list . -1 +1; __DATA__ -X File a file test (-r, -x, etc) @@ -205,6 +268,7 @@ oct String,Math convert a string to an octal number open File open a file, pipe, or descriptor opendir File open a directory ord String find a character's numeric representation +our Misc,Namespace declare and assign a package variable (lexical scoping) pack Binary,String convert a list into a binary representation pipe Process open a pair of connected filehandles pop ARRAY remove the last element from an array and return it diff --git a/lib/Pod/t/Functions.t b/lib/Pod/t/Functions.t new file mode 100644 index 0000000000..601aa50c9d --- /dev/null +++ b/lib/Pod/t/Functions.t @@ -0,0 +1,158 @@ +#!perl + +BEGIN { + chdir 't' if -d 't'; + @INC = '../lib'; +} + +use File::Basename; +use File::Spec; + +use Test::More; +plan tests => 9; + + +use_ok( 'Pod::Functions' ); + +# How do you test exported vars? +my( $pkg_ref, $exp_ref ) = ( \%Pod::Functions::Kinds, \%Kinds ); +is( $pkg_ref, $exp_ref, '%Pod::Functions::Kinds exported' ); + +( $pkg_ref, $exp_ref ) = ( \%Pod::Functions::Type, \%Type ); +is( $pkg_ref, $exp_ref, '%Pod::Functions::Type exported' ); + +( $pkg_ref, $exp_ref ) = ( \%Pod::Functions::Flavor, \%Flavor ); +is( $pkg_ref, $exp_ref, '%Pod::Functions::Flavor exported' ); + +( $pkg_ref, $exp_ref ) = ( \%Pod::Functions::Type_Description, + \%Type_Description ); +is( $pkg_ref, $exp_ref, '%Pod::Functions::Type_Description exported' ); + +( $pkg_ref, $exp_ref ) = ( \@Pod::Functions::Type_Order, \@Type_Order ); +is( $pkg_ref, $exp_ref, '@Pod::Functions::Type_Order exported' ); + +# Check @Type_Order +my @catagories = qw( + String Regexp Math ARRAY LIST HASH I/O + Binary File Flow Namespace Misc Process Modules + Objects Socket SysV User Network Time +); + +ok( eq_array( \@Type_Order, \@catagories ), + '@Type_Order' ); + +my @cat_keys = grep exists $Type_Description{ $_ } => @Type_Order; + +ok( eq_array( \@cat_keys, \@catagories ), + 'keys() %Type_Description' ); + +my( undef, $path ) = fileparse( $0 ); +my $pod_functions = File::Spec->catfile( + $path, File::Spec->updir, 'Functions.pm' ); + +SKIP: { + my $test_out = do { local $/; <DATA> }; + + skip( "Can't fork '$^X': $!", 1) + unless open my $fh, qq[$^X "-I../lib" $pod_functions |]; + my $fake_out = do { local $/; <$fh> }; + skip( "Pipe error: $!", 1) + unless close $fh; + + is( $fake_out, $test_out, 'run as plain program' ); +} + +=head1 NAME + +Functions.t - Test Pod::Functions + +=head1 AUTHOR + +20011229 Abe Timmerman <abe@ztreet.demon.nl> + +=cut + +__DATA__ + +Functions for SCALARs or strings: + chomp, chop, chr, crypt, hex, index, lc, lcfirst, length, + oct, ord, pack, q/STRING/, qq/STRING/, reverse, rindex, + sprintf, substr, tr///, uc, ucfirst, y/// + +Regular expressions and pattern matching: + m//, pos, qr/PATTERN/, quotemeta, s///, split, study + +Numeric functions: + abs, atan2, cos, exp, hex, int, log, oct, rand, sin, sqrt, + srand + +Functions for real @ARRAYs: + pop, push, shift, splice, unshift + +Functions for list data: + grep, join, map, qw/STRING/, reverse, sort, unpack + +Functions for real %HASHes: + delete, each, exists, keys, values + +Input and output functions: + binmode, close, closedir, dbmclose, dbmopen, die, eof, + fileno, flock, format, getc, print, printf, read, readdir, + readline, rewinddir, seek, seekdir, select, syscall, + sysread, sysseek, syswrite, tell, telldir, truncate, warn, + write + +Functions for fixed length data or records: + pack, read, syscall, sysread, sysseek, syswrite, unpack, + vec + +Functions for filehandles, files, or directories: + -X, chdir, chmod, chown, chroot, fcntl, glob, ioctl, link, + lstat, mkdir, open, opendir, readlink, rename, rmdir, + stat, symlink, umask, unlink, utime + +Keywords related to control flow of your perl program: + caller, continue, die, do, dump, eval, exit, goto, last, + next, prototype, redo, return, sub, wantarray + +Keywords altering or affecting scoping of identifiers: + caller, import, local, my, our, package, use + +Miscellaneous functions: + defined, dump, eval, formline, local, my, our, prototype, + reset, scalar, undef, wantarray + +Functions for processes and process groups: + alarm, exec, fork, getpgrp, getppid, getpriority, kill, + pipe, qx/STRING/, setpgrp, setpriority, sleep, system, + times, wait, waitpid + +Keywords related to perl modules: + do, import, no, package, require, use + +Keywords related to classes and object-orientedness: + bless, dbmclose, dbmopen, package, ref, tie, untie, use + +Low-level socket functions: + accept, bind, connect, getpeername, getsockname, + getsockopt, listen, recv, send, setsockopt, shutdown, + socket, socketpair + +System V interprocess communication functions: + msgctl, msgget, msgrcv, msgsnd, semctl, semget, semop, + shmctl, shmget, shmread, shmwrite + +Fetching user and group info: + endgrent, endhostent, endnetent, endpwent, getgrent, + getgrgid, getgrnam, getlogin, getpwent, getpwnam, + getpwuid, setgrent, setpwent + +Fetching network info: + endprotoent, endservent, gethostbyaddr, gethostbyname, + gethostent, getnetbyaddr, getnetbyname, getnetent, + getprotobyname, getprotobynumber, getprotoent, + getservbyname, getservbyport, getservent, sethostent, + setnetent, setprotoent, setservent + +Time-related functions: + gmtime, localtime, time, times diff --git a/lib/unicore/Is/SpacePerl.pl b/lib/unicore/Is/SpacePerl.pl index 3866aee9ee..cc8f50a638 100644 --- a/lib/unicore/Is/SpacePerl.pl +++ b/lib/unicore/Is/SpacePerl.pl @@ -5,6 +5,7 @@ return <<'END'; 0009 000A 000C 000D 0020 +0085 00A0 1680 2000 200B diff --git a/lib/unicore/mktables b/lib/unicore/mktables index 34d138826b..067af24b6a 100644 --- a/lib/unicore/mktables +++ b/lib/unicore/mktables @@ -134,7 +134,7 @@ sub gencat { ||= [], $code); # 005F: SPACING UNDERSCORE $op->($Cat->{Word} ||= [], $code) - if $cat =~ /^[LMN]/ or $code eq "005F"; + if $cat =~ /^[LMN]/ || $code eq "005F"; $op->($Cat->{Alnum} ||= [], $code) if $cat =~ /^[LMN]/; $op->($Cat->{Alpha} ||= [], $code) @@ -149,7 +149,7 @@ sub gencat { if $cat =~ /^Z/ || $code =~ /^(0009|000A|000B|000C|000D)$/; $op->($Cat->{SpacePerl} ||= [], $code) - if $cat =~ /^Z/ || + if $cat =~ /^Z/ || $code =~ /^(?:0085|2028|2029)$/ || $code =~ /^(0009|000A|000C|000D)$/; $op->($Cat->{Blank} ||= [], $code) if $code =~ /^(0020|0009)$/ || @@ -12,6 +12,10 @@ * come here, and I don't want to see no more magic,' he said, and fell silent." */ +/* +=head1 Magical Functions +*/ + #include "EXTERN.h" #define PERL_IN_MG_C #include "perl.h" @@ -12,6 +12,10 @@ * wizards count differently to other people." */ +/* +=head1 Numeric functions +*/ + #include "EXTERN.h" #define PERL_IN_NUMERIC_C #include "perl.h" @@ -15,6 +15,7 @@ * either way, as the saying is, if you follow me." --the Gaffer */ + #include "EXTERN.h" #define PERL_IN_OP_C #include "perl.h" @@ -3453,6 +3454,8 @@ Perl_utilize(pTHX_ int aver, I32 floor, OP *version, OP *id, OP *arg) } /* +=head1 Embedding Functions + =for apidoc load_module Loads the module whose name is pointed to by the string part of name. @@ -4632,6 +4635,9 @@ Perl_cv_ckproto(pTHX_ CV *cv, GV *gv, char *p) static void const_sv_xsub(pTHX_ CV* cv); /* + +=head1 Optree Manipulation Functions + =for apidoc cv_const_sv If C<cv> is a constant sub eligible for inlining. returns the constant @@ -6781,9 +6787,16 @@ Perl_ck_subr(pTHX_ OP *o) goto again; break; case ']': - if (contextclass) - contextclass = 0; - else + if (contextclass) { + char *p = proto; + char s = *p; + contextclass = 0; + *p = '\0'; + while (*--p != '['); + bad_type(arg, Perl_form("one of %s", p), + gv_ename(namegv), o2); + *proto = s; + } else goto oops; break; case '*': @@ -59,6 +59,8 @@ typedef U64TYPE PADOFFSET; dfl) /* +=head1 "Gimme" Values + =for apidoc Amn|U32|GIMME_V The XSUB-writer's equivalent to Perl's C<wantarray>. Returns C<G_VOID>, C<G_SCALAR> or C<G_ARRAY> for void, scalar or list context, diff --git a/patchlevel.h b/patchlevel.h index 9b36ef0ea4..8e7458efd9 100644 --- a/patchlevel.h +++ b/patchlevel.h @@ -70,7 +70,7 @@ #if !defined(PERL_PATCHLEVEL_H_IMPLICIT) && !defined(LOCAL_PATCH_COUNT) static char *local_patches[] = { NULL - ,"DEVEL14014" + ,"DEVEL14041" ,NULL }; @@ -102,6 +102,8 @@ perl_alloc_using(struct IPerlMem* ipM, struct IPerlMem* ipMS, #else /* +=head1 Embedding Functions + =for apidoc perl_alloc Allocates a new Perl interpreter. See L<perlembed>. @@ -1622,6 +1624,8 @@ S_run_body(pTHX_ I32 oldscope) } /* +=head1 SV Manipulation Functions + =for apidoc p||get_sv Returns the SV of the specified Perl scalar. If C<create> is set and the @@ -1649,6 +1653,8 @@ Perl_get_sv(pTHX_ const char *name, I32 create) } /* +=head1 Array Manipulation Functions + =for apidoc p||get_av Returns the AV of the specified Perl array. If C<create> is set and the @@ -1670,6 +1676,8 @@ Perl_get_av(pTHX_ const char *name, I32 create) } /* +=head1 Hash Manipulation Functions + =for apidoc p||get_hv Returns the HV of the specified Perl hash. If C<create> is set and the @@ -1691,6 +1699,8 @@ Perl_get_hv(pTHX_ const char *name, I32 create) } /* +=head1 CV Manipulation Functions + =for apidoc p||get_cv Returns the CV of the specified Perl subroutine. If C<create> is set and @@ -1722,6 +1732,9 @@ Perl_get_cv(pTHX_ const char *name, I32 create) /* Be sure to refetch the stack pointer after calling these routines. */ /* + +=head1 Callback Functions + =for apidoc p||call_argv Performs a callback to the specified Perl sub. See L<perlcall>. @@ -2103,6 +2116,8 @@ Perl_eval_pv(pTHX_ const char *p, I32 croak_on_error) /* Require a module. */ /* +=head1 Embedding Functions + =for apidoc p||require_pv Tells Perl to C<require> the file named by the string argument. It is diff --git a/pod/perldelta.pod b/pod/perldelta.pod index a074ead057..0ae001b51d 100644 --- a/pod/perldelta.pod +++ b/pod/perldelta.pod @@ -2595,7 +2595,7 @@ from the CPAN. If you find what you think is a bug, you might check the articles recently posted to the comp.lang.perl.misc newsgroup and the perl bug database at http://bugs.perl.org. There may also be -information at http://www.perl.com/perl/, the Perl Home Page. +information at http://www.perl.com/, the Perl Home Page. If you believe you have an unreported bug, please run the B<perlbug> program included with your release. Be sure to trim your bug down diff --git a/pod/perldiag.pod b/pod/perldiag.pod index 90ed552ddd..29358eacac 100644 --- a/pod/perldiag.pod +++ b/pod/perldiag.pod @@ -543,9 +543,9 @@ quotas or other plumbing problems. =item Can't declare class for non-scalar %s in "%s" -(F) Currently, only scalar variables can declared with a specific class -qualifier in a "my" or "our" declaration. The semantics may be extended -for other types of variables in future. +(F) Currently, only scalar variables can be declared with a specific +class qualifier in a "my" or "our" declaration. The semantics may be +extended for other types of variables in future. =item Can't declare %s in "%s" @@ -1289,6 +1289,11 @@ something that isn't defined yet, you don't actually have to define the subroutine or package before the current location. You can use an empty "sub foo;" or "package FOO;" to enter a "forward" declaration. +=item dump() better written as CORE::dump() + +(W misc) You used the obsolescent C<dump()> built-in function, without fully +qualifying it as C<CORE::dump()>. Maybe it's a typo. See L<perlfunc/dump>. + =item Duplicate free() ignored (S malloc) An internal routine called free() on something that had @@ -3171,11 +3176,9 @@ account you tested it under), does not rely on any environment variables location where the CGI server can't find it, basically, more or less. Please see the following for more information: - http://www.cpan.org/doc/FAQs/cgi/idiots-guide.html - http://www.cpan.org/doc/FAQs/cgi/perl-cgi-faq.html - ftp://rtfm.mit.edu/pub/usenet/news.answers/www/cgi-faq - http://hoohoo.ncsa.uiuc.edu/cgi/interface.html - http://www-genome.wi.mit.edu/WWW/faqs/www-security-faq.html + http://www.perl.org/CGI_MetaFAQ.html + http://www.htmlhelp.org/faq/cgifaq.html + http://www.w3.org/Security/Faq/ You should also look at L<perlfaq9>. diff --git a/pod/perlfaq.pod b/pod/perlfaq.pod index e0649fb5af..26290783c0 100644 --- a/pod/perlfaq.pod +++ b/pod/perlfaq.pod @@ -1296,14 +1296,13 @@ How can I do RPC in Perl? =head2 Where to get the perlfaq This document is posted regularly to comp.lang.perl.announce and -several other related newsgroups. It is available in a variety of -formats from CPAN in the /CPAN/doc/FAQs/FAQ/ directory or on the web -at http://www.perl.com/perl/faq/ . +several other related newsgroups. It is available on many +web sites: http://www.perldoc.com/ and http://perlfaq.cpan.org/ . =head2 How to contribute to the perlfaq You may mail corrections, additions, and suggestions to -perlfaq-suggestions@perl.com . This alias should not be +perlfaq-workers@perl.org . This alias should not be used to I<ask> FAQs. It's for fixing the current FAQ. Send questions to the comp.lang.perl.misc newsgroup. @@ -1311,7 +1310,7 @@ Send questions to the comp.lang.perl.misc newsgroup. Your questions will probably go unread, unless they're suggestions of new questions to add to the FAQ, in which case they should have gone -to the perlfaq-suggestions@perl.com instead. +to the perlfaq-workers@perl.org instead. You should have read section 2 of this faq. There you would have learned that comp.lang.perl.misc is the appropriate place to go for diff --git a/pod/perlfaq1.pod b/pod/perlfaq1.pod index e9b1ef7184..682c8150b5 100644 --- a/pod/perlfaq1.pod +++ b/pod/perlfaq1.pod @@ -35,8 +35,11 @@ for Perl's milestone releases. In particular, the core development team (known as the Perl Porters) are a rag-tag band of highly altruistic individuals committed to producing better software for free than you could hope to purchase for -money. You may snoop on pending developments via -nntp://news.perl.com/perl.porters-gw/ +money. You may snoop on pending developments via the archives at +http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/ +and http://archive.develooper.com/perl5-porters@perl.org/ +or the news gateway news://news.perl.com/perl.porters-gw/ , +or read the faq at http://perlhacker.org/p5p-faq, or you can subscribe to the mailing list by sending perl5-porters-request@perl.org a subscription request (an empty message with no subject is fine). diff --git a/pod/perlfaq2.pod b/pod/perlfaq2.pod index 71be980e10..b6068fa5ab 100644 --- a/pod/perlfaq2.pod +++ b/pod/perlfaq2.pod @@ -129,6 +129,7 @@ miscellaneous modules. See http://www.cpan.org/modules/00modlist.long.html or http://search.cpan.org/ for a more complete list of modules by category. +CPAN is not affiliated with O'Reilly and Associates. =head2 Is there an ISO or ANSI certified version of Perl? @@ -493,7 +494,7 @@ bugs. Read the perlbug(1) man page (perl5.004 or later) for more information. -=head2 What is perl.com? Perl Mongers? pm.org? perl.org? +=head2 What is perl.com? Perl Mongers? pm.org? perl.org? cpan.org? The Perl Home Page at http://www.perl.com/ is currently hosted by The O'Reilly Network, a subsidiary of O'Reilly and Associates. @@ -519,6 +520,10 @@ and there are many other sub-domains for special topics, such as http://news.perl.org/ http://use.perl.org/ +http://www.cpan.org/ is the Comprehensive Perl Archive Network, +a replicated worlwide repository of Perl software, see +the I<What is CPAN?> question earlier in this document. + =head1 AUTHOR AND COPYRIGHT Copyright (c) 1997-2001 Tom Christiansen and Nathan Torkington. diff --git a/pod/perlfaq3.pod b/pod/perlfaq3.pod index 7e0c193da7..a592c57387 100644 --- a/pod/perlfaq3.pod +++ b/pod/perlfaq3.pod @@ -22,8 +22,9 @@ Have you read the appropriate manpages? Here's a brief index: Regexes perlre, perlfunc, perlop, perllocale Moving to perl5 perltrap, perl Linking w/C perlxstut, perlxs, perlcall, perlguts, perlembed - Various http://www.cpan.org/doc/FMTEYEWTK/index.html - (not a man-page but still useful) + Various http://www.cpan.org/misc/olddoc/FMTEYEWTK.tgz + (not a man-page but still useful, a collection + of various essays on Perl techniques) A crude table of contents for the Perl manpage set is found in L<perltoc>. @@ -154,13 +155,9 @@ for indenting, ^D is for undenting, and ^O is for blockdenting-- as it were. A more complete example, with comments, can be found at http://www.cpan.org/authors/id/TOMC/scripts/toms.exrc.gz -If you are used to using the I<vgrind> program for printing out nice code -to a laser printer, you can take a stab at this using -http://www.cpan.org/doc/misc/tips/working.vgrind.entry, but the -results are not particularly satisfying for sophisticated code. - -The a2ps at http://www.infres.enst.fr/%7Edemaille/a2ps/ does lots of things -related to generating nicely printed output of documents. +The a2ps http://www-inf.enst.fr/%7Edemaille/a2ps/black+white.ps does +lots of things related to generating nicely printed output of +documents, as does enscript at http://people.ssh.fi/mtr/genscript/. =head2 Is there a ctags for Perl? @@ -873,9 +870,13 @@ guides and references in L<perlfaq9> or in the CGI MetaFAQ: =head2 Where can I learn about object-oriented Perl programming? A good place to start is L<perltoot>, and you can use L<perlobj>, -L<perlboot>, and L<perlbot> for reference. Perltoot didn't come out -until the 5.004 release; you can get a copy (in pod, html, or -postscript) from http://www.cpan.org/doc/FMTEYEWTK/ . +L<perlboot>, L<perltoot>, L<perltooc>, and L<perlbot> for reference. +(If you are using really old Perl, you may not have all of these, +try http://www.perldoc.com/ , but consider upgrading your perl.) + +A good book on OO on Perl is the "Object-Oriented Perl" +by Damian Conway from Manning Publications, +http://www.manning.com/Conway/index.html =head2 Where can I learn about linking C with Perl? [h2xs, xsubpp] diff --git a/pod/perlfaq4.pod b/pod/perlfaq4.pod index e816fb3893..abbb9a03cb 100644 --- a/pod/perlfaq4.pod +++ b/pod/perlfaq4.pod @@ -1,6 +1,6 @@ =head1 NAME -perlfaq4 - Data Manipulation ($Revision: 1.9 $, $Date: 2001/12/07 21:17:58 $) +perlfaq4 - Data Manipulation ($Revision: 1.10 $, $Date: 2002/01/01 22:26:45 $) =head1 DESCRIPTION @@ -333,10 +333,11 @@ call C<srand> more than once--you make your numbers less random, rather than more. Computers are good at being predictable and bad at being random -(despite appearances caused by bugs in your programs :-). -http://www.cpan.org/doc/FMTEYEWTK/random , courtesy of Tom -Phoenix, talks more about this. John von Neumann said, ``Anyone who -attempts to generate random numbers by deterministic means is, of +(despite appearances caused by bugs in your programs :-). see the +F<random> artitcle in the "Far More Than You Ever Wanted To Know" +collection in http://www.cpan.org/olddoc/FMTEYEWTK.tgz , courtesy of +Tom Phoenix, talks more about this. John von Neumann said, ``Anyone +who attempts to generate random numbers by deterministic means is, of course, living in a state of sin.'' If you want numbers that are more random than C<rand> with C<srand> @@ -1473,8 +1474,9 @@ If you need to sort on several fields, the following paradigm is useful. This can be conveniently combined with precalculation of keys as given above. -See http://www.cpan.org/doc/FMTEYEWTK/sort.html for more about -this approach. +See the F<sort> artitcle article in the "Far More Than You Ever Wanted +To Know" collection in http://www.cpan.org/olddoc/FMTEYEWTK.tgz for +more about this approach. See also the question below on sorting hashes. diff --git a/pod/perlfaq5.pod b/pod/perlfaq5.pod index 80a8fb6fff..ef7b5cb73f 100644 --- a/pod/perlfaq5.pod +++ b/pod/perlfaq5.pod @@ -1128,9 +1128,9 @@ documentation for details. =head2 Why does Perl let me delete read-only files? Why does C<-i> clobber protected files? Isn't this a bug in Perl? -This is elaborately and painstakingly described in the "Far More Than -You Ever Wanted To Know" in -http://www.cpan.org/doc/FMTEYEWTK/file-dir-perms . +This is elaborately and painstakingly described in the +F<file-dir-perms> article in the "Far More Than You Ever Wanted To +Know" collection in http://www.cpan.org/olddoc/FMTEYEWTK.tgz . The executive summary: learn how your filesystem works. The permissions on a file say what can happen to the data in that file. diff --git a/pod/perlfaq6.pod b/pod/perlfaq6.pod index 91323fab31..6bca28342a 100644 --- a/pod/perlfaq6.pod +++ b/pod/perlfaq6.pod @@ -1,6 +1,6 @@ =head1 NAME -perlfaq6 - Regexes ($Revision: 1.5 $, $Date: 2001/12/02 01:55:12 $) +perlfaq6 - Regexes ($Revision: 1.6 $, $Date: 2002/01/01 22:26:45 $) =head1 DESCRIPTION diff --git a/pod/perlfaq7.pod b/pod/perlfaq7.pod index 7aec723071..69bc17f473 100644 --- a/pod/perlfaq7.pod +++ b/pod/perlfaq7.pod @@ -1,6 +1,6 @@ =head1 NAME -perlfaq7 - Perl Language Issues ($Revision: 1.4 $, $Date: 2001/11/07 02:27:50 $) +perlfaq7 - Perl Language Issues ($Revision: 1.5 $, $Date: 2002/01/01 22:26:45 $) =head1 DESCRIPTION diff --git a/pod/perlfaq8.pod b/pod/perlfaq8.pod index bf5d7a6a6f..0f65a30762 100644 --- a/pod/perlfaq8.pod +++ b/pod/perlfaq8.pod @@ -634,9 +634,10 @@ STDOUT). Note that you I<must> use Bourne shell (sh(1)) redirection syntax in backticks, not csh(1)! Details on why Perl's system() and backtick -and pipe opens all use the Bourne shell are in -http://www.cpan.org/doc/FMTEYEWTK/versus/csh.whynot . -To capture a command's STDERR and STDOUT together: +and pipe opens all use the Bourne shell are in the +F<versus/csh.whynot> article in the "Far More Than You Ever Wanted To +Know" collection in http://www.cpan.org/olddoc/FMTEYEWTK.tgz . To +capture a command's STDERR and STDOUT together: $output = `cmd 2>&1`; # either with backticks $pid = open(PH, "cmd 2>&1 |"); # or with an open pipe diff --git a/pod/perlfunc.pod b/pod/perlfunc.pod index 93383d3f01..4bd69a3f14 100644 --- a/pod/perlfunc.pod +++ b/pod/perlfunc.pod @@ -1204,7 +1204,9 @@ resulting confusion on the part of Perl. This function is now largely obsolete, partly because it's very hard to convert a core file into an executable, and because the real compiler backends for generating portable bytecode and compilable -C code have superseded it. +C code have superseded it. That's why you should now invoke it as +C<CORE::dump()>, if you don't want to be warned against a possible +typo. If you're looking to use L<dump> to speed up your program, consider generating bytecode or native C code as described in L<perlcc>. If diff --git a/pod/perlhack.pod b/pod/perlhack.pod index 4efe90bfe2..c93e230dbc 100644 --- a/pod/perlhack.pod +++ b/pod/perlhack.pod @@ -1891,6 +1891,15 @@ If you plan to use the "Viewer" windows, then you only need this option: setenv PURIFYOPTIONS "-chain-length=25" +In Bourne-type shells: + + PURIFY_OPTIONS="..." + export PURIFY_OPTIONS + +or if you have the "env" utility: + + env PURIFY_OPTIONS="..." ../pureperl ... + =head2 Purify on NT Purify on Windows NT instruments the Perl binary 'perl.exe' diff --git a/pod/perllocale.pod b/pod/perllocale.pod index 7864addc3e..43ffe584ac 100644 --- a/pod/perllocale.pod +++ b/pod/perllocale.pod @@ -310,6 +310,10 @@ locale "En_US"--and in Cshish shells (B<csh>, B<tcsh>) setenv LC_ALL en_US.ISO8859-1 +or if you have the "env" application you can do in any shell + + env LC_ALL=en_US.ISO8859-1 perl ... + If you do not know what shell you have, consult your local helpdesk or the equivalent. diff --git a/pod/perlmodlib.PL b/pod/perlmodlib.PL index 9b3536f1ee..9a62369863 100644 --- a/pod/perlmodlib.PL +++ b/pod/perlmodlib.PL @@ -165,8 +165,7 @@ CPAN stands for Comprehensive Perl Archive Network; it's a globally replicated trove of Perl materials, including documentation, style guides, tricks and traps, alternate ports to non-Unix systems and occasional binary distributions for these. Search engines for -CPAN can be found at http://cpan.perl.com/ and at -http://theory.uwinnipeg.ca/mod_perl/cpan-search.pl . +CPAN can be found at http://www.cpan.org/. Most importantly, CPAN includes around a thousand unbundled modules, some of which require a C compiler to build. Major categories of diff --git a/pod/perlmodlib.pod b/pod/perlmodlib.pod index 67ea1a314d..8ad8072bab 100644 --- a/pod/perlmodlib.pod +++ b/pod/perlmodlib.pod @@ -53,10 +53,6 @@ The following pragmas are defined (and have their own documentation). Get/set subroutine or variable attributes -=item attrs - -Set/get attributes of a subroutine (deprecated) - =item autouse Postpone load of modules until a function is used @@ -113,18 +109,10 @@ Use and avoid POSIX locales for built-in operations Set default disciplines for input and output -=item ops - -Restrict unsafe operations when compiling - =item overload Package for overloading perl operations -=item re - -Alter regular expression behaviour - =item sigtrap Enable simple signal handling @@ -175,6 +163,10 @@ Exporter module. See their own documentation for details. Provide framework for multiple DBMs +=item Attribute::Handlers + +Simpler definition of attribute handlers + =item AutoLoader Load subroutines only on demand @@ -183,82 +175,10 @@ Load subroutines only on demand Split a package for autoloading -=item B - -The Perl Compiler - -=item B::Asmdata - -Autogenerated data about Perl ops, used to generate bytecode - -=item B::Assembler - -Assemble Perl bytecode - -=item B::Bblock - -Walk basic blocks - -=item B::Bytecode - -Perl compiler's bytecode backend - -=item B::C - -Perl compiler's C backend - -=item B::CC - -Perl compiler's optimized C translation backend - -=item B::Concise - -Walk Perl syntax tree, printing concise info about ops - -=item B::Debug - -Walk Perl syntax tree, printing debug info about ops - -=item B::Deparse - -Perl compiler backend to produce perl code - -=item B::Disassembler - -Disassemble Perl bytecode - -=item B::Lint - -Perl lint - -=item B::Showlex - -Show lexical variables used in functions or files - -=item B::Stackobj - -Helper module for CC backend - -=item B::Stash - -Show what stashes are loaded - -=item B::Terse - -Walk Perl syntax tree, printing terse info about ops - -=item B::Xref - -Generates cross reference reports for Perl programs - =item Benchmark Benchmark running times of Perl code -=item ByteLoader - -Load byte compiled perl code - =item CGI Simple Common Gateway Interface Class @@ -331,10 +251,6 @@ Get pathname of current working directory Programmatic interface to the Perl debugging API (draft, subject to -=item DB_File - -Perl5 access to Berkeley DB version 1.x - =item Devel::SelfStubber Generate stubs for a SelfLoading module @@ -351,18 +267,6 @@ Supply object methods for directory handles Provides screen dump of Perl data. -=item Encode - -Character encodings - -=item Encode::EncodeFormat - -The format of encoding tables of the Encode extension - -=item Encode::Tcl - -Tcl encodings - =item English Use nice English (or awk) names for ugly punctuation variables @@ -455,10 +359,6 @@ Add blib/* directories to @INC Replace functions with equivalents which succeed or die -=item Fcntl - -Load the C Fcntl.h defines - =item File::Basename Split a pathname into pieces @@ -491,6 +391,10 @@ Create or remove directory trees Portably perform operations on file names +=item File::Spec::Cygwin + +Methods for Cygwin file specs + =item File::Spec::Epoc Methods for Epoc file specs @@ -563,10 +467,6 @@ Functions for dealing with RFC3066-style language tags Tags and names for human languages -=item IO - -Load various IO modules - =item IPC::Open2 Open a process for both reading and writing @@ -651,10 +551,6 @@ Glue to provide EXISTS for SDBM_File for Storable use Store Memoized data in Storable database -=item NDBM_File - -Tied access to ndbm files - =item NEXT Provide a pseudo-class NEXT that allows method redispatch @@ -719,22 +615,6 @@ By-name interface to Perl's built-in getproto*() functions By-name interface to Perl's built-in getserv*() functions -=item O - -Generic interface to Perl Compiler backends - -=item ODBM_File - -Tied access to odbm files - -=item Opcode - -Disable named opcodes when compiling perl code - -=item POSIX - -Perl interface to IEEE Std 1003.1 - =item PerlIO On demand loader for PerlIO layers and root of PerlIO::* name space @@ -747,6 +627,10 @@ Check pod documents for syntax errors Find POD documents in directory trees +=item Pod::Functions + +Group Perl's functions a la perlfunc.pod + =item Pod::Html Module to convert pod files to HTML @@ -807,14 +691,6 @@ Print a usage message from embedded pod documentation Test of various basic POD features in translators. -=item SDBM_File - -Tied access to sdbm files - -=item Safe - -Compile and execute code in restricted compartments - =item Search::Dict Search for key in dictionary file @@ -831,14 +707,6 @@ Load functions only on demand Run shell commands transparently within perl -=item Socket - -Load the C socket.h defines and structure manipulators - -=item Storable - -Persistency for perl data structures - =item Switch A switch statement for Perl @@ -1015,8 +883,7 @@ CPAN stands for Comprehensive Perl Archive Network; it's a globally replicated trove of Perl materials, including documentation, style guides, tricks and traps, alternate ports to non-Unix systems and occasional binary distributions for these. Search engines for -CPAN can be found at http://cpan.perl.com/ and at -http://theory.uwinnipeg.ca/mod_perl/cpan-search.pl . +CPAN can be found at http://www.cpan.org/. Most importantly, CPAN includes around a thousand unbundled modules, some of which require a C compiler to build. Major categories of diff --git a/pod/perlre.pod b/pod/perlre.pod index feafb0e654..58cd6456f5 100644 --- a/pod/perlre.pod +++ b/pod/perlre.pod @@ -188,14 +188,18 @@ In addition, Perl defines the following: NOTE: breaks up characters into their UTF-8 bytes, so you may end up with malformed pieces of UTF-8. -A C<\w> matches a single alphanumeric character or C<_>, not a whole word. -Use C<\w+> to match a string of Perl-identifier characters (which isn't -the same as matching an English word). If C<use locale> is in effect, the -list of alphabetic characters generated by C<\w> is taken from the -current locale. See L<perllocale>. You may use C<\w>, C<\W>, C<\s>, C<\S>, +A C<\w> matches a single alphanumeric character (an alphabetic +character, or a decimal digit) or C<_>, not a whole word. Use C<\w+> +to match a string of Perl-identifier characters (which isn't the same +as matching an English word). If C<use locale> is in effect, the list +of alphabetic characters generated by C<\w> is taken from the current +locale. See L<perllocale>. You may use C<\w>, C<\W>, C<\s>, C<\S>, C<\d>, and C<\D> within character classes, but if you try to use them -as endpoints of a range, that's not a range, the "-" is understood literally. -See L<perlunicode> for details about C<\pP>, C<\PP>, and C<\X>. +as endpoints of a range, that's not a range, the "-" is understood +literally. If Unicode is in effect, C<\s> matches also "\x{85}", +"\x{2028}, and "\x{2029}", see L<perlunicode> for more details about +C<\pP>, C<\PP>, and C<\X>, and L<perluniintro> about Unicode in +general. The POSIX character class syntax @@ -228,11 +232,11 @@ A GNU extension equivalent to C<[ \t]>, `all horizontal whitespace'. =item [2] Not exactly equivalent to C<\s> since the C<[[:space:]]> includes -also the (very rare) `vertical tabulator', \ck", chr(11). +also the (very rare) `vertical tabulator', "\ck", chr(11). =item [3] -A Perl extension. +A Perl extension, see above. =back diff --git a/pod/perlretut.pod b/pod/perlretut.pod index 8f7c8cdd72..e90e03d602 100644 --- a/pod/perlretut.pod +++ b/pod/perlretut.pod @@ -1738,7 +1738,7 @@ traditional Unicode classes: IsPrint /^([LMNPS]|Co|Zs)/ IsPunct /^P/ IsSpace /^Z/ || ($code =~ /^(0009|000A|000B|000C|000D)$/ - IsSpacePerl /^Z/ || ($code =~ /^(0009|000A|000C|000D)$/ + IsSpacePerl /^Z/ || ($code =~ /^(0009|000A|000C|000D|0085|2028|2029)$/ IsUpper /^L[ut]/ IsWord /^[LMN]/ || $code eq "005F" IsXDigit $code =~ /^00(3[0-9]|[46][1-6])$/ diff --git a/pod/perlrun.pod b/pod/perlrun.pod index 138e34499c..7326d27064 100644 --- a/pod/perlrun.pod +++ b/pod/perlrun.pod @@ -334,6 +334,9 @@ If you're just trying to get a print out of each line of Perl code as it executes, the way that C<sh -x> provides for shell scripts, you can't use Perl's B<-D> switch. Instead do this + # If you have "env" utility + env=PERLDB_OPTS="NonStop=1 AutoTrace=1 frame=2" perl -dS program + # Bourne shell syntax $ PERLDB_OPTS="NonStop=1 AutoTrace=1 frame=2" perl -dS program @@ -3180,12 +3180,12 @@ PP(pp_crypt) char *tmps = SvPV(left, len); char *t = 0; if (DO_UTF8(left)) { - /* If Unicode take the crypt() of the low 8 bits - * of the characters of the string. */ + /* If Unicode take the crypt() of the low 8 bits of + * the characters of the string. Yes, we made this up. */ char *s = tmps; char *send = tmps + len; STRLEN i = 0; - Newz(688, t, len, char); + Newz(688, t, len + 1, char); while (s < send) { t[i++] = utf8_to_uvchr((U8*)s, 0) & 0xFF; s += UTF8SKIP(s); @@ -18,6 +18,8 @@ #define PP(s) OP * Perl_##s(pTHX) /* +=head1 Stack Manipulation Macros + =for apidoc AmU||SP Stack pointer. This is usually handled by C<xsubpp>. See C<dSP> and C<SPAGAIN>. @@ -1368,6 +1368,8 @@ S_qsortsv(pTHX_ gptr *list1, size_t nmemb, SVCOMPARE_t cmp) } /* +=head1 Array Manipulation Functions + =for apidoc sortsv Sort an array. Here is an example: @@ -5,7 +5,6 @@ */ - START_EXTERN_C #if defined(PERL_IMPLICIT_SYS) @@ -1331,10 +1330,7 @@ PERL_CALLCONV STRLEN Perl_sv_utf8_upgrade_flags(pTHX_ SV *sv, I32 flags); PERL_CALLCONV char* Perl_sv_pvn_force_flags(pTHX_ SV* sv, STRLEN* lp, I32 flags); PERL_CALLCONV char* Perl_sv_2pv_flags(pTHX_ SV* sv, STRLEN* lp, I32 flags); PERL_CALLCONV char* Perl_my_atof2(pTHX_ const char *s, NV* value); -#if !defined(HAS_SOCKETPAIR) && defined(HAS_SOCKET) PERL_CALLCONV int Perl_my_socketpair(int family, int type, int protocol, int fd[2]); -#endif - #if defined(USE_PERLIO) && !defined(USE_SFIO) PERL_CALLCONV int Perl_PerlIO_close(pTHX_ PerlIO *); @@ -3137,7 +3137,7 @@ tryagain: if (ISMULT2(p)) { /* Back off on ?+*. */ if (len) p = oldp; - else if (!UNI_IS_INVARIANT(NATIVE_TO_UNI(ender)) && UTF) { + else if (UTF) { if (FOLD) { /* Emit all the Unicode characters. */ for (foldbuf = tmpbuf; @@ -3162,7 +3162,7 @@ tryagain: } break; } - if (!UNI_IS_INVARIANT(NATIVE_TO_UNI(ender)) && UTF) { + if (UTF) { if (FOLD) { /* Emit all the Unicode characters. */ for (foldbuf = tmpbuf; @@ -4025,9 +4025,10 @@ S_regclass(pTHX_ RExC_state_t *pRExC_state) to_utf8_fold(tmpbuf, foldbuf, &foldlen); f = utf8_to_uvchr(foldbuf, 0); - /* If folding and foldable, insert also - * the folded version to the charclass. */ - if (f != value) + /* If folding and foldable and a single + * character, insert also the folded version + * to the charclass. */ + if (f != value && foldlen == UNISKIP(f)) Perl_sv_catpvf(aTHX_ listsv, "%04"UVxf"\n", f); /* If folding and the value is one of the Greek @@ -986,8 +986,8 @@ S_find_byclass(pTHX_ regexp * prog, regnode *c, char *s, char *strend, char *sta c = utf8_to_uvchr((U8*)s, &len); if ( c == c1 && (ln == len || - ibcmp_utf8(s, 0 , 0, do_utf8, - m, 0 , ln, UTF)) + ibcmp_utf8(s, (char **)0, 0, do_utf8, + m, (char **)0, ln, UTF)) && (norun || regtry(prog, s)) ) goto got_it; else { @@ -996,10 +996,10 @@ S_find_byclass(pTHX_ regexp * prog, regnode *c, char *s, char *strend, char *sta if ( f != c && (f == c1 || f == c2) && (ln == foldlen || - !ibcmp_utf8((char *)foldbuf, - 0, foldlen, do_utf8, + !ibcmp_utf8((char *) foldbuf, + (char **)0, foldlen, do_utf8, m, - 0, ln, UTF)) + (char **)0, ln, UTF)) && (norun || regtry(prog, s)) ) goto got_it; } @@ -1023,8 +1023,8 @@ S_find_byclass(pTHX_ regexp * prog, regnode *c, char *s, char *strend, char *sta if ( (c == c1 || c == c2) && (ln == len || - ibcmp_utf8(s, 0, 0, do_utf8, - m, 0, ln, UTF)) + ibcmp_utf8(s, (char **)0, 0, do_utf8, + m, (char **)0, ln, UTF)) && (norun || regtry(prog, s)) ) goto got_it; else { @@ -1034,9 +1034,9 @@ S_find_byclass(pTHX_ regexp * prog, regnode *c, char *s, char *strend, char *sta && (f == c1 || f == c2) && (ln == foldlen || !ibcmp_utf8((char *)foldbuf, - 0, foldlen, do_utf8, + (char **)0, foldlen, do_utf8, m, - 0, ln, UTF)) + (char **)0, ln, UTF)) && (norun || regtry(prog, s)) ) goto got_it; } @@ -55,6 +55,8 @@ #define SSPOPDXPTR (PL_savestack[--PL_savestack_ix].any_dxptr) /* +=head1 Callback Functions + =for apidoc Ams||SAVETMPS Opening bracket for temporaries on a callback. See C<FREETMPS> and L<perlcall>. diff --git a/sharedsv.c b/sharedsv.c index e4b6e0ff36..f0cba10d98 100644 --- a/sharedsv.c +++ b/sharedsv.c @@ -33,6 +33,8 @@ */ /* +=head1 Shared SV Functions + =for apidoc sharedsv_init Saves a space for keeping SVs wider than an interpreter, @@ -216,6 +216,8 @@ S_del_sv(pTHX_ SV *p) /* +=head1 SV Manipulation Functions + =for apidoc sv_add_arena Given a chunk of memory, link it to the head of the list of arenas, @@ -10386,6 +10388,8 @@ perl_clone_using(PerlInterpreter *proto_perl, UV flags, #endif /* USE_ITHREADS */ /* +=head1 Unicode Support + =for apidoc sv_recode_to_utf8 The encoding is assumed to be an Encode object, on entry the PV @@ -12,6 +12,8 @@ #endif /* +=head1 SV Flags + =for apidoc AmU||svtype An enum of flags for Perl types. These are found in the file B<sv.h> in the C<svtype> enum. Test these flags with the C<SvTYPE> macro. @@ -98,6 +100,8 @@ struct io { }; /* +=head1 SV Manipulation Functions + =for apidoc Am|U32|SvREFCNT|SV* sv Returns the value of the object's reference count. @@ -1139,6 +1143,8 @@ incremented. /* the following macros update any magic values this sv is associated with */ /* +=head1 Magical Functions + =for apidoc Am|void|SvGETMAGIC|SV* sv Invokes C<mg_get> on an SV if it has 'get' magic. This macro evaluates its argument more than once. @@ -1161,6 +1167,8 @@ Like C<SvSetSV>, but does any set magic required afterwards. =for apidoc Am|void|SvSetMagicSV_nosteal|SV* dsv|SV* ssv Like C<SvSetMagicSV>, but does any set magic required afterwards. +=head1 SV Manipulation Functions + =for apidoc Am|char *|SvGROW|SV* sv|STRLEN len Expands the character buffer in the SV so that it has room for the indicated number of bytes (remember to reserve space for an extra trailing diff --git a/t/comp/proto.t b/t/comp/proto.t index 32b1fad8ee..4141f2abc6 100755 --- a/t/comp/proto.t +++ b/t/comp/proto.t @@ -16,7 +16,7 @@ BEGIN { use strict; -print "1..135\n"; +print "1..140\n"; my $i = 1; @@ -526,6 +526,23 @@ print "ok ", $i++, "\n"; print "ok ", $i++, "\n"; print "not " unless myref(*myglob) =~ /^GLOB\(/; print "ok ", $i++, "\n"; + + eval q/sub multi1 (\[%@]) { 1 } multi1 $myvar;/; + print "not " unless $@ =~ /Type of arg 1 to main::multi1 must be one of/; + print "ok ", $i++, "\n"; + eval q/sub multi2 (\[$*&]) { 1 } multi2 @myarray;/; + print "not " unless $@ =~ /Type of arg 1 to main::multi2 must be one of/; + print "ok ", $i++, "\n"; + eval q/sub multi3 (\[$@]) { 1 } multi3 %myhash;/; + print "not " unless $@ =~ /Type of arg 1 to main::multi3 must be one of/; + print "ok ", $i++, "\n"; + eval q/sub multi4 ($\[%]) { 1 } multi4 1, &mysub;/; + print "not " unless $@ =~ /Type of arg 2 to main::multi4 must be one of/; + print "ok ", $i++, "\n"; + eval q/sub multi5 (\[$@]$) { 1 } multi5 *myglob;/; + print "not " unless $@ =~ /Type of arg 1 to main::multi5 must be one of/ + && $@ =~ /Not enough arguments/; + print "ok ", $i++, "\n"; } # check that obviously bad prototypes are getting warnings diff --git a/t/lib/warnings/toke b/t/lib/warnings/toke index 14b745da22..70ff3dbbf6 100644 --- a/t/lib/warnings/toke +++ b/t/lib/warnings/toke @@ -101,6 +101,8 @@ toke.c AOK $a = 0037777777776 ; $a = 0037777777777 ; $a = 0047777777777 ; + + dump() better written as CORE::dump() Mandatory Warnings ------------------ @@ -702,6 +704,23 @@ Integer overflow in hexadecimal number at - line 8. Integer overflow in octal number at - line 11. ######## # toke.c +BEGIN { $^C = 1; } +use warnings 'misc'; +dump; +CORE::dump; +EXPECT +dump() better written as CORE::dump() at - line 4. +- syntax OK +######## +# toke.c +use warnings 'misc'; +use subs qw/dump/; +sub dump { print "no warning for overriden dump\n"; } +dump; +EXPECT +no warning for overriden dump +######## +# toke.c use warnings 'ambiguous'; "@mjd_previously_unused_array"; no warnings 'ambiguous'; diff --git a/t/op/pat.t b/t/op/pat.t index 5cdb2e5ad2..bc2ed375ab 100755 --- a/t/op/pat.t +++ b/t/op/pat.t @@ -6,7 +6,7 @@ $| = 1; -print "1..834\n"; +print "1..843\n"; BEGIN { chdir 't' if -d 't'; @@ -2578,3 +2578,44 @@ print "# some Unicode properties\n"; print ":$S3:" =~ /:(([$sigma])+):/i && $1 eq $S3 && $2 eq $sigma ? "ok 834\n" : "not ok 834\n"; } + +{ + print "# LATIN SMALL LETTER SHARP S\n"; + + use charnames ':full'; + + print "\N{LATIN SMALL LETTER SHARP S}" =~ + /\N{LATIN SMALL LETTER SHARP S}/ ? "ok 835\n" : "not ok 835\n"; + + print "\N{LATIN SMALL LETTER SHARP S}" =~ + /\N{LATIN SMALL LETTER SHARP S}/i ? "ok 836\n" : "not ok 836\n"; + + print "\N{LATIN SMALL LETTER SHARP S}" =~ + /[\N{LATIN SMALL LETTER SHARP S}]/ ? "ok 837\n" : "not ok 837\n"; + + print "\N{LATIN SMALL LETTER SHARP S}" =~ + /[\N{LATIN SMALL LETTER SHARP S}]/i ? "ok 838\n" : "not ok 838\n"; + + print "ss" =~ + /\N{LATIN SMALL LETTER SHARP S}/i ? "ok 839\n" : "not ok 839\n"; + + print "SS" =~ + /\N{LATIN SMALL LETTER SHARP S}/i ? "ok 840\n" : "not ok 840\n"; + +# Fix coming up. +# print "ss" =~ +# /[\N{LATIN SMALL LETTER SHARP S}]/i ? "ok 841\n" : "not ok 841\n"; +# +# print "SS" =~ +# /[\N{LATIN SMALL LETTER SHARP S}]/i ? "ok 842\n" : "not ok 842\n"; +} + +{ + print "# more whitespace: U+0085, U+2028, U+2029\n"; + + # U+0085 needs to be forced to be Unicode, the \x{100} does that. + print "<\x{100}\x{0085}>" =~ /<\x{100}\s>/ ? "ok 841\n" : "not ok 841\n"; + print "<\x{2028}>" =~ /<\s>/ ? "ok 842\n" : "not ok 842\n"; + print "<\x{2029}>" =~ /<\s>/ ? "ok 843\n" : "not ok 843\n"; +} + diff --git a/t/op/stat.t b/t/op/stat.t index 2f18382fa8..4857836ddf 100755 --- a/t/op/stat.t +++ b/t/op/stat.t @@ -210,9 +210,9 @@ SKIP: { skip "opendir failed: $!", 3 if @DEV == 0; # /dev/stdout might be either character special or a named pipe, - # depending on which OS and how are you running the test, so let's - # censor that one away. - $DEV =~ s{^[cp].+?\sstdout$}{}m; + # or a symlink, or a socket, depending on which OS and how are + # you running the test, so let's censor that one away. + $DEV =~ s{^[cpls].+?\sstdout$}{}m; @DEV = grep { $_ ne 'stdout' } @DEV; # /dev/printer is also naughty: in IRIX it shows up as diff --git a/t/op/system.t b/t/op/winsystem.t index 22dcd8bbfa..22dcd8bbfa 100644 --- a/t/op/system.t +++ b/t/op/winsystem.t @@ -1,3 +1,7 @@ +/* +=head1 Global Variables +*/ + /***********************************************/ /* Global only to current thread */ /***********************************************/ @@ -3813,6 +3813,10 @@ Perl_yylex(pTHX) } else { /* no override */ tmp = -tmp; + if (tmp == KEY_dump && ckWARN(WARN_MISC)) { + Perl_warner(aTHX_ WARN_MISC, + "dump() better written as CORE::dump()"); + } gv = Nullgv; gvp = 0; if (ckWARN(WARN_AMBIGUOUS) && hgv diff --git a/universal.c b/universal.c index 868fe55140..8fc7d699a8 100644 --- a/universal.c +++ b/universal.c @@ -93,6 +93,8 @@ S_isa_lookup(pTHX_ HV *stash, const char *name, int len, int level) } /* +=head1 SV Manipulation Functions + =for apidoc sv_derived_from Returns a boolean indicating whether the SV is derived from the specified @@ -24,9 +24,9 @@ #define PERL_IN_UTF8_C #include "perl.h" -/* Unicode support */ +/* +=head1 Unicode Support -/* =for apidoc A|U8 *|uvuni_to_utf8_flags|U8 *d|UV uv|UV flags Adds the UTF8 representation of the Unicode codepoint C<uv> to the end @@ -488,6 +488,8 @@ Perl_rninstr(pTHX_ register const char *big, const char *bigend, const char *lit If FBMcf_TAIL, the table is created as if the string has a trailing \n. */ /* +=head1 Miscellaneous Functions + =for apidoc fbm_compile Analyses the string in order to make fast searches on it using fbm_instr() @@ -877,6 +879,8 @@ Perl_ibcmp_locale(pTHX_ const char *s1, const char *s2, register I32 len) /* copy a string to a safe spot */ /* +=head1 Memory Management + =for apidoc savepv Copy a string to a safe spot. This does not use an SV. @@ -955,6 +959,7 @@ Perl_form_nocontext(const char* pat, ...) #endif /* PERL_IMPLICIT_CONTEXT */ /* +=head1 Miscellaneous Functions =for apidoc form Takes a sprintf-style format pattern and conventional @@ -1285,6 +1290,8 @@ Perl_croak_nocontext(const char *pat, ...) #endif /* PERL_IMPLICIT_CONTEXT */ /* +=head1 Warning and Dieing + =for apidoc croak This is the XSUB-writer's interface to Perl's C<die> function. @@ -3759,6 +3766,8 @@ return FALSE (dp->d_name[1] == '.' && dp->d_name[2] == '\0'))) /* +=head1 Miscellaneous Functions + =for apidoc getcwd_sv Fill the sv with current working directory @@ -3921,6 +3930,8 @@ Perl_getcwd_sv(pTHX_ register SV *sv) } /* +=head1 SV Manipulation Functions + =for apidoc new_vstring Returns a pointer to the next character after the parsed @@ -4224,3 +4235,12 @@ Perl_my_socketpair (int family, int type, int protocol, int fd[2]) { } } #endif /* !defined(HAS_SOCKETPAIR) && defined(HAS_SOCKET) */ +#ifdef HAS_SOCKETPAIR +/* In any case have a stub so that there's code corresponding + * to the my_socketpair in global.sym. */ +int +Perl_my_socketpair (int family, int type, int protocol, int fd[2]) { + return socketpair(family, type, protocol, fd); +} +#endif + |