----------------
+Version 5.003_93
+----------------
+
+Me, last time:
+ "This release will be the public beta of 5.004,
+ or my name isn't Larson T. Pettifogger."
+Me, now:
+ "Gone like *that*, a fortune in letterhead."
+
+ CORE LANGUAGE CHANGES
+
+ Title: "Don't autovivify array and hash elements in sub parameters"
+ From: Gurusamy Sarathy <gsar@engin.umich.edu>
+ Msg-ID: <199703061912.OAA20606@aatma.engin.umich.edu>
+ Date: Thu, 06 Mar 1997 14:12:09 -0500
+ Files: op.c pod/perldelta.pod pod/perlsub.pod pod/perltrap.pod
+
+ Title: "Support READ and GETC for tied handles"
+ From: Doug MacEachern <dougm@opengroup.org>
+ Msg-ID: <199703090019.TAA32591@postman.osf.org>
+ Date: Sat, 08 Mar 1997 19:19:38 -0500
+ Files: pod/perldelta.pod pod/perltie.pod pp_sys.c t/op/misc.t
+
+ Title: "Warn on C<@x =~ /a/> and C<%x =~ s/a/b/>"
+ From: Chip Salzenberg
+ Files: op.c pod/perldiag.pod
+
+ Title: "Warn on %{+undef} and @{+undef}"
+ From: Chip Salzenberg
+ Files: pp.c pp_hot.c
+
+ CORE PORTABILITY
+
+ Title: "VMS update"
+ From: Charles Bailey <bailey@HMIVAX.HUMGEN.UPENN.EDU>
+ Msg-ID: <01IG8KN5R28M00661G@hmivax.humgen.upenn.edu>
+ Date: Fri, 07 Mar 1997 22:49:46 -0500 (EST)
+ Files: lib/ExtUtils/MM_VMS.pm vms/descrip.mms vms/gen_shrfls.pl
+ vms/sockadapt.h
+
+ Title: "AmigaOS hint patch"
+ From: "Norbert Pueschel" <pueschel@imsdd.meb.uni-bonn.de>
+ Msg-ID: <77724767@Armageddon.meb.uni-bonn.de>
+ Date: Sat, 08 Mar 1997 12:50:15 +0100
+ Files: hints/amigaos.sh
+
+ OTHER CORE CHANGES
+
+ Title: "Make conversion of @_ to real array work right after C<shift>"
+ From: Chip Salzenberg
+ Files: av.c
+
+ Title: "Fix imbalanced ENTER/LEAVE from C<BEGIN{die}>"
+ From: Chip Salzenberg
+ Files: op.c perl.c proto.h
+
+ Title: "perl -P path patch"
+ From: Andy Dougherty <doughera@fractal.phys.lafayette.edu>
+ Msg-ID: <Pine.SOL.3.95q.970308120242.23766D-100000@fractal.lafayette.
+ Date: Sat, 08 Mar 1997 12:45:08 -0500 (EST)
+ Files: config_H config_h.SH perl.c plan9/config.plan9 t/comp/cpp.t
+ vms/config.vms win32/config.H
+
+ BUILD PROCESS
+
+ Title: "Fix for Unisys UNIX and libperl.so"
+ From: aburlison@cix.compulink.co.uk (Alan Burlison)
+ Msg-ID: <memo.147328@cix.compulink.co.uk>
+ Date: Thu, 6 Mar 97 16:28 GMT0
+ Files: Configure
+
+ Title: "Allow './Configure -Uoptimize'"
+ From: Andy Dougherty <doughera@fractal.phys.lafayette.edu>
+ Msg-ID: <Pine.SOL.3.95q.970306110532.11070A-100000@fractal.lafayette.
+ Date: Thu, 06 Mar 1997 11:15:47 -0500 (EST)
+ Files: Configure
+
+ Title: "Use 'test -f', not 'test -x'"
+ From: Spider Boardman <spider@web.zk3.dec.com>
+ Msg-ID: <199703080053.TAA13943@web.zk3.dec.com>
+ Date: Fri, 7 Mar 1997 19:53:00 -0500
+ Files: Configure
+
+ Title: "Don't count on 'trap 0' inside () in shell script"
+ From: aburlison@cix.compulink.co.uk (Alan Burlison)
+ Msg-ID: <memo.147326@cix.compulink.co.uk>
+ Date: Thu, 6 Mar 97 16:28 GMT0
+ Files: perl_exp.SH
+
+ LIBRARY AND EXTENSIONS
+
+ Title: "Carp with multiple arguments"
+ From: "M.J.T. Guy" <mjtg@cus.cam.ac.uk>
+ Msg-ID: <E0w3STZ-0007RW-00@taurus.cus.cam.ac.uk>
+ Date: Sat, 8 Mar 1997 20:12:17 +0000
+ Files: lib/Carp.pm
+
+ Title: "@EXPORT_FAIL fix for Exporter.pm"
+ From: Roderick Schertler <roderick@argon.org>
+ Msg-ID: <24884.857841724@eeyore.ibcinc.com>
+ Date: Sat, 08 Mar 1997 12:22:04 -0500
+ Files: lib/Exporter.pm
+
+ Title: "Open[23] autoflush docs"
+ From: Roderick Schertler <roderick@argon.org>
+ Msg-ID: <7939.857693947@eeyore.ibcinc.com>
+ Date: Thu, 06 Mar 1997 19:19:07 -0500
+ Files: lib/IPC/Open2.pm lib/IPC/Open3.pm
+
+ TESTS
+
+ Title: "Fix counts in output of TEST"
+ From: Hugo van der Sanden <hv@iii.co.uk>
+ Msg-ID: <331F1507.4BE8@iii.co.uk>
+ Date: Thu, 06 Mar 1997 19:03:35 +0000
+ Files: t/TEST
+
+ Title: "Ignore backup files in strict.t and warning.t"
+ From: Chip Salzenberg
+ Files: t/pragma/strict.t t/pragma/warning.t
+
+ UTILITIES
+
+ Title: "Quote pathname before using as pattern"
+ From: Chip Salzenberg
+ Files: pod/pod2html.PL
+
+ DOCUMENTATION
+
+ Title: "Consolidated INSTALL updates since _92"
+ From: Andy Dougherty <doughera@fractal.phys.lafayette.edu>
+ Msg-ID: <Pine.SOL.3.95q.970308131806.23766F-100000@fractal.lafayette.
+ Date: Sat, 08 Mar 1997 13:21:22 -0500 (EST)
+
+ Title: "Fix more E-Mail addresses in pods"
+ From: Chip Salzenberg
+ Files: lib/ExtUtils/MakeMaker.pm lib/ExtUtils/Manifest.pm
+ lib/diagnostics.pm pod/buildtoc
+
+ Title: "Warn about '.' terminating E-Mail"
+ From: Chip Salzenberg
+ Files: pod/perlform.pod
+
+ Title: "OS/2 doc update"
+ From: Ilya Zakharevich <ilya@math.ohio-state.edu>
+ Msg-ID: <199703080537.AAA25157@monk.mps.ohio-state.edu>
+ Date: Sat, 8 Mar 1997 00:37:30 -0500 (EST)
+ Files: README.os2
+
+ Title: "PODs corrections"
+ From: Ilya Zakharevich <ilya@math.ohio-state.edu>
+ Msg-ID: <199703080253.VAA24975@monk.mps.ohio-state.edu>
+ Date: Fri, 7 Mar 1997 21:53:04 -0500 (EST)
+ Files: ext/DB_File/DB_File.pm ext/Socket/Socket.pm
+ lib/Class/Template.pm lib/ExtUtils/Embed.pm
+ lib/ExtUtils/MM_VMS.pm lib/ExtUtils/Mksymlists.pm
+ lib/File/Basename.pm lib/File/stat.pm lib/Time/gmtime.pm
+ lib/Time/localtime.pm lib/Time/tm.pm lib/User/grent.pm
+ lib/User/pwent.pm pod/perlcall.pod pod/perldebug.pod
+ pod/perlfunc.pod pod/perlguts.pod pod/perllocale.pod
+ pod/perlop.pod pod/perlsub.pod
+
+
+----------------
Version 5.003_92
----------------
t/lib/gdbm.t t/lib/ndbm.t t/lib/odbm.t t/lib/sdbm.t
t/op/magic.t t/op/stat.t
- #20: "Hints for DC/OSx"
+ Title: "Hints for DC/OSx"
From: Stephen Zander <srz@loopback>
Msg-ID: <199702242124.NAA03796@wsuse5.mckesson.com>
Date: Mon, 24 Feb 1997 13:24:54 -0800
: determine optimize, if desired, or use for debug flag also
case "$optimize" in
-' ') dflt='none';;
+' '|$undef) dflt='none';;
'') dflt='-O';;
*) dflt="$optimize";;
esac
nm_opt='-p' # Solaris (and SunOS?)
elif $test -f /dgux; then
nm_opt='-p' # DG-UX
- elif $test -x /lib64/rld; then
+ elif $test -f /lib64/rld; then
nm_opt='-p' # 64-bit Irix
else
nm_opt=''
;;
*) case "$useshrplib" in
'') case "$osname" in
- svr4|dgux|dynixptx|esix|powerux)
+ svr4*|dgux|dynixptx|esix|powerux)
dflt='yes'
also='Building a shared libperl is required for dynamic loading to work on your system.'
;;
Each of these is explained in further detail below.
For information on non-Unix systems, see the section on
-L<"Porting Information"> below.
+L<"Porting information"> below.
=head1 DESCRIPTION
=over 4
+=item -DDEBUGGING_MSTATS
+
+If C<DEBUGGING_MSTATS> is defined, you can extract malloc
+statistics from the Perl interpreter. The overhead this imposes is not
+large (perl just twiddles integers at malloc/free/sbrk time). When you
+run perl with the environment variable C<PERL_DEBUG_MSTATS> set to
+either 1 or 2, the interpreter will dump statistics to stderr at exit
+time and (with a value of 2) after compilation. If you install the
+Devel::Peek module you can get the statistics whenever you like by
+invoking its mstat() function.
+
=item -DEMERGENCY_SBRK
-If this macro is defined, running out of memory need not be a fatal
-error: a memory pool can allocated by assigning to the special
-variable C<$^M>.
+If C<EMERGENCY_SBRK> is defined, running out of memory need not be a
+fatal error: a memory pool can allocated by assigning to the special
+variable C<$^M>. See L<perlvar> for more details.
=item -DPACK_MALLOC
=item Porting information
-Specific information for the OS/2, Plan9, VMS and Win32 ports are in the
+Specific information for the OS/2, Plan9, VMS and Win32 ports is in the
corresponding subdirectories. Additional information, including
a glossary of all those config.sh variables, is in the Porting
subdirectory.
=head1 LAST MODIFIED
-$Id: INSTALL,v 1.3 1997/02/28 16:34:11 doughera Released $
+$Id: INSTALL,v 1.5 1997/03/08 18:15:49 doughera Released $
* This symbol holds the path of the bin directory where the package will
* be installed. Program must be prepared to deal with ~name substitution.
*/
+/* BIN_EXP:
+ * This symbol is the filename expanded version of the BIN symbol, for
+ * programs that do not want to deal with that at run-time.
+ */
#define BIN "/opt/perl/bin" /**/
+#define BIN_EXP "/opt/perl/bin" /**/
/* CAT2:
* This macro catenates 2 tokens together.
*/
#define RANDBITS 15 /**/
-/* SCRIPTDIR:
- * This symbol holds the name of the directory in which the user wants
- * to put publicly executable scripts for the package in question. It
- * is often a directory that is mounted across diverse architectures.
- * Programs must be prepared to deal with ~name expansion.
- */
-#define SCRIPTDIR "/opt/perl/script" /**/
-
/* Select_fd_set_t:
* This symbol holds the type used for the 2nd, 3rd, and 4th
* arguments to select. Usually, this is 'fd_set *', if HAS_FD_SET
* This symbol holds the path of the bin directory where the package will
* be installed. Program must be prepared to deal with ~name substitution.
*/
+/* BIN_EXP:
+ * This symbol is the filename expanded version of the BIN symbol, for
+ * programs that do not want to deal with that at run-time.
+ */
#define BIN "$bin" /**/
+#define BIN_EXP "$binexp" /**/
/* CAT2:
* This macro catenates 2 tokens together.
*/
#define RANDBITS $randbits /**/
-/* SCRIPTDIR:
- * This symbol holds the name of the directory in which the user wants
- * to put publicly executable scripts for the package in question. It
- * is often a directory that is mounted across diverse architectures.
- * Programs must be prepared to deal with ~name expansion.
- */
-#define SCRIPTDIR "$scriptdir" /**/
-
/* Select_fd_set_t:
* This symbol holds the type used for the 2nd, 3rd, and 4th
* arguments to select. Usually, this is 'fd_set *', if HAS_FD_SET
undef $db ;
untie %hash ;
-See L<The untie gotcha> for more details.
+See L<The untie Gotcha> for more details.
All the functions defined in L<dbopen> are available except for
close() and dbopen() itself. The B<DB_File> method interface to the
In addition, some structure manipulation functions are available:
+=over
+
=item inet_aton HOSTNAME
Takes a string giving the name of a host, and translates that
and returns the pathname. Will croak if the structure does not
have AF_UNIX in the right place.
+=back
+
=cut
use Carp;
=head1 EXAMPLES
+=over
+
=item * Example 1
use Class::Template;
bless $r;
}
+=back
+
=head1 NOTES
Use '%' if the member should point to an anonymous hash. Use '@' if the
=head1 FUNCTIONS
+=over
+
=item xsinit()
Generate C/C++ code for the XS initializer function.
B<xsinit()> uses the xsi_* functions to generate most of it's code.
+=back
+
=head1 EXAMPLES
For examples on how to use B<ExtUtils::Embed> for building C/C++ applications
=head2 Methods always loaded
+=over
+
=item eliminate_macros
Expands MM[KS]/Make macros in a text string, using the contents of
ExtUtils::Liblist::ext(@_);
}
+=back
=head2 SelfLoaded methods
of why this method overrides the MM_Unix method; see the ExtUtils::MM_Unix
documentation for more details.
+=over
+
=item guess_name (override)
Try to determine name of extension being built. We begin with the name
sub dist {
my($self, %attribs) = @_;
$attribs{VERSION} ||= $self->{VERSION_SYM};
+ $attribs{NAME} ||= $self->{DISTNAME};
$attribs{ZIPFLAGS} ||= '-Vu';
$attribs{COMPRESS} ||= 'gzip';
$attribs{SUFFIX} ||= '-gz';
$attribs{SHAR} ||= 'vms_share';
$attribs{DIST_DEFAULT} ||= 'zipdist';
+ # Sanitize these for use in $(DISTVNAME) filespec
+ $attribs{VERSION} =~ s/[^\w\$]/_/g;
+ $attribs{NAME} =~ s/[^\w\$]/_/g;
+
return ExtUtils::MM_Unix::dist($self,%attribs);
}
my($self) = @_;
q[
dist : $(DIST_DEFAULT)
- $(NOECHO) $(PERL) -le "print 'Warning: $m older than $vf' if -e ($vf = '$(VERSION_FROM)') && -M $vf < -M ($m = '$(MAKEFILE)'"
+ $(NOECHO) $(PERL) -le "print 'Warning: $m older than $vf' if -e ($vf = '$(VERSION_FROM)') && -M $vf < -M ($m = '$(MAKEFILE)')"
zipdist : $(DISTVNAME).zip
$(NOECHO) $(NOOP)
$(DISTVNAME).zip : distdir
$(PREOP)
- $(ZIP) "$(ZIPFLAGS)" $(MMS$TARGET) $(SRC)
+ $(ZIP) "$(ZIPFLAGS)" $(MMS$TARGET) [.$(DISTVNAME)...]*.*;
$(RM_RF) $(DISTVNAME)
$(POSTOP)
$(DISTVNAME).tar$(SUFFIX) : distdir
$(PREOP)
$(TO_UNIX)
- $(TAR) "$(TARFLAGS)" $(DISTVNAME).tar $(SRC)
+ $(TAR) "$(TARFLAGS)" $(DISTVNAME).tar [.$(DISTVNAME)]
$(RM_RF) $(DISTVNAME)
$(COMPRESS) $(DISTVNAME).tar
$(POSTOP)
shdist : distdir
$(PREOP)
- $(SHARE) $(SRC) $(DISTVNAME).share
+ $(SHAR) [.$(DISTVNAME...]*.*; $(DISTVNAME).share
$(RM_RF) $(DISTVNAME)
$(POSTOP)
];
1;
+=back
+
+=cut
+
__END__
It takes one argument, a list of key-value pairs, in which the following
keys are recognized:
+=over
+
=item NAME
This gives the name of the extension (I<e.g.> Tk::Canvas) for which
name of the extension). If it is not specified, it is derived
from the NAME attribute. It is presently used only by OS2.
+=back
+
When calling C<Mksymlists>, one should always specify the NAME
attribute. In most cases, this is all that's necessary. In
the case of unusual extensions, however, the other attributes
$dir eq 'Doc_Root:[Help]'
$type eq '.Rnh'
+=over
+
=item C<basename>
The basename() routine returns the first element of the list produced
considers the directory name to be F<lib/>, while dirname() considers the
directory name to be F<.>).
+=back
+
=cut
require 5.002;
=head1 NAME
-File::stat.pm - by-name interface to Perl's built-in stat() functions
+File::stat - by-name interface to Perl's built-in stat() functions
=head1 SYNOPSIS
=head1 NAME
-Time::gmtime.pm - by-name interface to Perl's built-in gmtime() function
+Time::gmtime - by-name interface to Perl's built-in gmtime() function
=head1 SYNOPSIS
=head1 NAME
-Time::localtime.pm - by-name interface to Perl's built-in localtime() function
+Time::localtime - by-name interface to Perl's built-in localtime() function
=head1 SYNOPSIS
=head1 NAME
-Time::tm.pm - internal object used by Time::gmtime and Time::localtime
+Time::tm - internal object used by Time::gmtime and Time::localtime
=head1 SYNOPSIS
=head1 NAME
-User::grent.pm - by-name interface to Perl's built-in getgr*() functions
+User::grent - by-name interface to Perl's built-in getgr*() functions
=head1 SYNOPSIS
=head1 NAME
-User::pwent.pm - by-name interface to Perl's built-in getpw*() functions
+User::pwent - by-name interface to Perl's built-in getpw*() functions
=head1 SYNOPSIS
{
OP *op;
+ if (dowarn &&
+ (left->op_type == OP_RV2AV ||
+ left->op_type == OP_RV2HV ||
+ left->op_type == OP_PADAV ||
+ left->op_type == OP_PADHV)) {
+ char *desc = op_desc[(right->op_type == OP_SUBST ||
+ right->op_type == OP_TRANS)
+ ? right->op_type : OP_MATCH];
+ char *sample = ((left->op_type == OP_RV2AV ||
+ left->op_type == OP_PADAV)
+ ? "@array" : "%hash");
+ warn("Applying %s to %s will act on scalar(%s)", desc, sample, sample);
+ }
+
if (right->op_type == OP_MATCH ||
right->op_type == OP_SUBST ||
right->op_type == OP_TRANS) {
else
s = name;
if (strEQ(s, "BEGIN") && !error_count) {
+ I32 oldscope = scopestack_ix;
ENTER;
SAVESPTR(compiling.cop_filegv);
SAVEI16(compiling.cop_line);
DEBUG_x( dump_sub(gv) );
av_push(beginav, (SV *)cv);
GvCV(gv) = 0;
- calllist(beginav);
+ calllist(oldscope, beginav);
curcop = &compiling;
LEAVE;
}
else
list(o);
- mod(o, OP_ENTERSUB);
prev = o;
o = o->op_sibling;
}
#define PATCHLEVEL 3
-#define SUBVERSION 92
+#define SUBVERSION 93
/*
local_patches -- list of locally applied less-than-subversion patches.
char *scriptname = NULL;
VOL bool dosearch = FALSE;
char *validarg = "";
+ I32 oldscope;
AV* comppadlist;
#ifdef SETUID_SCRIPTS_ARE_SECURE_NOW
main_cv = Nullcv;
time(&basetime);
+ oldscope = scopestack_ix;
mustcatch = FALSE;
switch (Sigsetjmp(top_env,1)) {
/* FALL THROUGH */
case 2:
/* my_exit() was called */
+ while (scopestack_ix > oldscope)
+ LEAVE;
curstash = defstash;
if (endav)
- calllist(endav);
+ calllist(oldscope, endav);
return STATUS_NATIVE_EXPORT;
case 3:
mustcatch = FALSE;
perl_run(sv_interp)
PerlInterpreter *sv_interp;
{
+ I32 oldscope;
+
if (!(curinterp = sv_interp))
return 255;
+
+ oldscope = scopestack_ix;
+
switch (Sigsetjmp(top_env,1)) {
case 1:
cxstack_ix = -1; /* start context stack again */
break;
case 2:
/* my_exit() was called */
+ while (scopestack_ix > oldscope)
+ LEAVE;
curstash = defstash;
if (endav)
- calllist(endav);
+ calllist(oldscope, endav);
FREETMPS;
#ifdef DEBUGGING_MSTATS
if (getenv("PERL_DEBUG_MSTATS"))
extern int etext;
sprintf (buf, "%s.perldump", origfilename);
- sprintf (tokenbuf, "%s/perl", BIN);
+ sprintf (tokenbuf, "%s/perl", BIN_EXP);
status = unexec(buf, tokenbuf, &etext, sbrk(0), 0);
if (status)
char *cpp = CPPSTDIN;
if (strEQ(cpp,"cppstdin"))
- sprintf(tokenbuf, "%s/%s", SCRIPTDIR, cpp);
+ sprintf(tokenbuf, "%s/%s", BIN_EXP, cpp);
else
sprintf(tokenbuf, "%s", cpp);
sv_catpv(sv,"-I");
#ifndef IAMSUID /* in case script is not readable before setuid */
if (euid && Stat(SvPVX(GvSV(curcop->cop_filegv)),&statbuf) >= 0 &&
statbuf.st_mode & (S_ISUID|S_ISGID)) {
- (void)sprintf(buf, "%s/sperl%s", BIN, patchlevel);
+ (void)sprintf(buf, "%s/sperl%s", BIN_EXP, patchlevel);
execv(buf, origargv); /* try again */
croak("Can't do setuid\n");
}
if (euid) { /* oops, we're not the setuid root perl */
(void)PerlIO_close(rsfp);
#ifndef IAMSUID
- (void)sprintf(buf, "%s/sperl%s", BIN, patchlevel);
+ (void)sprintf(buf, "%s/sperl%s", BIN_EXP, patchlevel);
execv(buf, origargv); /* try again */
#endif
croak("Can't do setuid\n");
fcntl(PerlIO_fileno(rsfp),F_SETFD,0); /* ensure no close-on-exec */
#endif
- (void)sprintf(tokenbuf, "%s/perl%s", BIN, patchlevel);
+ (void)sprintf(tokenbuf, "%s/perl%s", BIN_EXP, patchlevel);
execv(tokenbuf, origargv); /* try again */
croak("Can't do setuid\n");
#endif /* IAMSUID */
}
void
-calllist(list)
+calllist(oldscope, list)
+I32 oldscope;
AV* list;
{
Sigjmp_buf oldtop;
sv_catpv(atsv, "BEGIN failed--compilation aborted");
else
sv_catpv(atsv, "END failed--cleanup aborted");
+ while (scopestack_ix > oldscope)
+ LEAVE;
croak("%s", SvPVX(atsv));
}
}
/* FALL THROUGH */
case 2:
/* my_exit() was called */
+ while (scopestack_ix > oldscope)
+ LEAVE;
curstash = defstash;
if (endav)
- calllist(endav);
+ calllist(oldscope, endav);
FREETMPS;
Copy(oldtop, top_env, 1, Sigjmp_buf);
curcop = &compiling;
-p9pvers = 5.003_92
+p9pvers = 5.003_93
* This symbol holds the path of the bin directory where the package will
* be installed. Program must be prepared to deal with ~name substitution.
*/
+/* BIN_EXP:
+ * This symbol is the filename expanded version of the BIN symbol, for
+ * programs that do not want to deal with that at run-time.
+ */
#define BIN "/_P9P_OBJTYPE/bin" /* */
+#define BIN_EXP "/_P9P_OBJTYPE/bin" /* */
/* BINCOMPAT3:
* This symbol, if defined, indicates that Perl 5.004 should be
*/
#define RANDBITS 15 /**/
-/* SCRIPTDIR:
- * This symbol holds the name of the directory in which the user wants
- * to put publicly executable scripts for the package in question. It
- * is often a directory that is mounted across diverse architectures.
- * Programs must be prepared to deal with ~name expansion.
- */
-#define SCRIPTDIR "/bin"
-
/* Select_fd_set_t:
* This symbol holds the type used for the 2nd, 3rd, and 4th
* arguments to select. Usually, this is 'fd_set *', if HAS_FD_SET
pushed onto the stack. In this case we are pushing a string and an
integer.
-See the L<perlguts/"XSUBs and the Argument Stack"> for details
+See the L<perlguts/"XSUB's and the Argument Stack"> for details
on how the XPUSH macros work.
=item 6.
See L<"Debugger Internals"> below for more details.
-=over 12
-
=item E<lt> [ command ]
Set an action (Perl command) to happen before every debugger prompt.
just as in the 5.003 release. By default, binary compatibility
is preserved at the expense of symbol table pollution.
-=head2 New Opcode Module and Revised Safe Module
+=head2 Subroutine Parameters Are Not Autovivified
-A new Opcode module supports the creation, manipulation and
-application of opcode masks. The revised Safe module has a new API
-and is implemented using the new Opcode module. Please read the new
-Opcode and Safe documentation.
+In Perl versions 5.002 and 5.003, array and hash elements used as
+subroutine parameters were "autovivified"; that is, they were brought
+into existence if they did not already exist. For example, calling
+C<func($h{foo})> would create C<$h{foo}> if it did not already exist,
+causing C<exists $h{foo}> to become true and C<keys %h> to return
+C<('foo')>.
+
+Perl 5.004 returns to the pre-5.002 behavior of I<not> autovivifying
+array and hash elements used as subroutine parameters.
=head2 Fixed Parsing of $$<digit>, &$<digit>, etc.
as a blessing, since that indicates a potentially-serious security
hole was just plugged.
+=head2 New Opcode Module and Revised Safe Module
+
+A new Opcode module supports the creation, manipulation and
+application of opcode masks. The revised Safe module has a new API
+and is implemented using the new Opcode module. Please read the new
+Opcode and Safe documentation.
+
=head2 Internal Change: FileHandle Class Based on IO::* Classes
File handles are now stored internally as type IO::Handle. The
Now, when perl sees that you're calling C<rand> and haven't yet called
C<srand>, it calls C<srand> with the default seed. You should still call
C<srand> manually if your code might ever be run on a pre-5.004 system,
-of course, or if you want a seed other than the default.
+of course, or if you want a seed other than the default.
=item $_ as Default
=item nested C<sub{}> closures work now
-Prior to the 5.004 release, nested anonymous functions
-didn't work right. They do now.
+Prior to the 5.004 release, nested anonymous functions didn't work
+right. They do now.
=item formats work right on changing lexicals
$i
.
write;
- }
+ }
=back
return an object of some sort. The reference can be used to
hold some internal information.
- sub TIEHANDLE {
- print "<shout>\n";
- my $i;
+ sub TIEHANDLE {
+ print "<shout>\n";
+ my $i;
return bless \$i, shift;
}
Beyond its self reference it also expects the list that was passed to
the print function.
- sub PRINT {
- $r = shift;
- $$r++;
+ sub PRINT {
+ $r = shift;
+ $$r++;
return print join( $, => map {uc} @_), $\;
}
+=item READ this LIST
+
+This method will be called when the handle is read from via the C<read>
+or C<sysread> functions.
+
+ sub READ {
+ $r = shift;
+ my($buf,$len,$offset) = @_;
+ print "READ called, \$buf=$buf, \$len=$len, \$offset=$offset";
+ }
+
=item READLINE this
This method will be called when the handle is read from. The method
should return undef when there is no more data.
- sub READLINE {
- $r = shift;
- return "PRINT called $$r times\n";
+ sub READLINE {
+ $r = shift;
+ return "PRINT called $$r times\n"
}
+=item GETC this
+
+This method will be called when the C<getc> function is called.
+
+ sub GETC { print "Don't GETC, Get Perl"; return "a"; }
+
=item DESTROY this
As with the other types of ties, this method will be called when the
tied handle is about to be destroyed. This is useful for debugging and
possibly for cleaning up.
- sub DESTROY {
+ sub DESTROY {
print "</shout>\n";
}
=head2 Malloc Enhancements
-If perl's malloc() is used, you can print memory statistics at runtime
-by running Perl thusly:
+Four new compilation flags are recognized by malloc.c. (They have no
+effect if perl is compiled with system malloc().)
+
+=over
+
+=item -DDEBUGGING_MSTATS
+
+If perl is compiled with C<DEBUGGING_MSTATS> defined, you can print
+memory statistics at runtime by running Perl thusly:
env PERL_DEBUG_MSTATS=2 perl your_script_here
(If you want the statistics at an arbitrary time, you'll need to
install the optional module Devel::Peek.)
-In addition, three new compilation flags are recognized by malloc.c.
-(They have no effect if perl is compiled with system malloc().)
-
-=over
-
=item -DEMERGENCY_SBRK
If this macro is defined, running out of memory need not be a fatal
provided that your operating system happens to support them:
F_GETOWN F_SETOWN
- O_ASYNC O_DEFER O_DSYNC O_FSYNC O_SYNC
+ O_ASYNC O_DEFER O_DSYNC O_FSYNC O_SYNC
O_EXLOCK O_SHLOCK
These constants are intended for use with the Perl operators sysopen()
Several new conditions will trigger warnings that were
silent before. Some only affect certain platforms.
-The following new warnings and errors outline these.
+The following new warnings and errors outline these.
These messages are classified as follows (listed in
increasing order of desperation):
You probably wrote something like this:
- @list = qw(
+ @list = qw(
a # a comment
b # another comment
);
when you should have written this:
@list = qw(
- a
+ a
b
);
delimiters than the parentheses shown here; braces are also frequently
used.)
-You probably wrote something like this:
+You probably wrote something like this:
qw! a, b, c !;
from innumerable contributors, with kibitzing by more than a few Perl
porters.
-Last update: Tue Jan 14 14:03:02 EST 1997
+Last update: Sat Mar 8 19:51:26 EST 1997
(F) You can't allocate more than 2^31+"small amount" bytes.
+=item Applying %s to %s will act on scalar(%s)
+
+(W) The pattern match (//), substitution (s///), and translation (tr///)
+operators work on scalar values. If you apply one of them to an array
+or a hash, it will convert the array or hash to a scalar value -- the
+length of an array, or the population info of a hash -- and then work on
+that scalar value. This is probably not what you meant to do. See
+L<perlfunc/grep> and L<perlfunc/map> for alternatives.
+
=item Arg too short for msgsnd
(F) msgsnd() requires a string at least as long as sizeof(long).
to modify the elements of the array. While this is useful and
supported, it can cause bizarre results if the LIST is not a named
array. Similarly, grep returns aliases into the original list,
-much like the way that L<foreach>'s index variable aliases the list
+much like the way that L<Foreach Loops>'s index variable aliases the list
elements. That is, modifying an element of a list returned by grep
actually modifies the element in the original list.
line and all will be well.
To free an SV that you've created, call C<SvREFCNT_dec(SV*)>. Normally this
-call is not necessary (see the section on L<Mortality>).
+call is not necessary (see the section on L<Reference Counts and Mortality>).
=head2 What's Really Stored in an SV?
SV* sv_bless(SV* sv, HV* stash);
The C<sv> argument must be a reference. The C<stash> argument specifies
-which class the reference will belong to. See the section on L<Stashes>
-for information on converting class names into stashes.
+which class the reference will belong to. See the section on
+L<Stashes and Globs> for information on converting class names into stashes.
/* Still under construction */
OP's in the compile tree of the unit can use the same target, if this
would not conflict with the expected life of the temporary.
-=head2 Scratchpads and recursions
+=head2 Scratchpads and recursion
In fact it is not 100% true that a compiled unit contains a pointer to
the scratchpad AV. In fact it contains a pointer to an AV of
If you want a Perl application to process and present your data
according to a particular locale, the application code should include
-the S<C<use locale>> pragma (see L<The use locale Pragma>) where
+the S<C<use locale>> pragma (see L<The use locale pragma>) where
appropriate, and B<at least one> of the following must be true:
=over 4
comparison of the transformed strings. By calling strxfrm() explicitly,
and using a non locale-affected comparison, the example attempts to save
a couple of transformations. In fact, it doesn't save anything: Perl
-magic (see L<perlguts/Magic>) creates the transformed version of a
+magic (see L<perlguts/Magic Variables>) creates the transformed version of a
string the first time it's needed in a comparison, then keeps it around
in case it's needed again. An example rewritten the easy way with
C<cmp> runs just about as fast. It also copes with null characters
environment suggested otherwise. By default, Perl still behaves this
way so as to maintain backward compatibility. If you want a Perl
application to pay attention to locale information, you B<must> use
-the S<C<use locale>> pragma (see L<The S<C<use locale>> Pragma>) to
+the S<C<use locale>> pragma (see L<The use locale Pragma>) to
instruct it to do so.
Versions of Perl from 5.002 to 5.003 did use the C<LC_CTYPE>
well as subroutine and method calls, and the anonymous
constructors C<[]> and C<{}>.
-See also L<Quote and Quote-Like Operators> toward the end of this section,
+See also L<Quote and Quote-like Operators> toward the end of this section,
as well as L<"I/O Operators">.
=head2 The Arrow Operator
Any arguments passed to the routine come in as the array @_. Thus if you
called a function with two arguments, those would be stored in C<$_[0]>
and C<$_[1]>. The array @_ is a local array, but its values are implicit
-references (predating L<perlref>) to the actual scalar parameters. What
-this means in practice is that when you explicitly modify C<$_[0]> et al.,
-you will be changing the actual arguments. As a result, all arguments
-to functions are treated as lvalues. Any hash or array elements that are
-passed to functions will get created if they do not exist (irrespective
-of whether the function does modify the contents of C<@_>). This is
-frequently a source of surprise. See L<perltrap> for an example.
-
-The return value of the subroutine is the value of the last expression
+references (predating L<perlref>) to the actual scalar parameters. The
+return value of the subroutine is the value of the last expression
evaluated. Alternatively, a return statement may be used to specify the
returned value and exit the subroutine. If you return one or more arrays
and/or hashes, these will be flattened together into one large
passing multiple arrays in a single LIST, because normally the LIST
mechanism will merge all the array values so that you can't extract out
the individual arrays. For more on typeglobs, see
-L<perldata/"Typeglobs and FileHandles">.
+L<perldata/"Typeglobs and Filehandles">.
=head2 Pass by Reference
It's probably worth mentioning that if you're going to filetest the
return values out of a readdir, you'd better prepend the directory
in question. Otherwise, because we didn't chdir() there, it would
-have been testing the wrong file.
+have been testing the wrong file.
=item FETCH this, key
This is partially implemented now.
-A class implementing a tied filehandle should define the following methods:
-TIEHANDLE, PRINT and/or READLINE, and possibly DESTROY.
+A class implementing a tied filehandle should define the following
+methods: TIEHANDLE, at least one of PRINT, READLINE, GETC, or READ,
+and possibly DESTROY.
It is especially useful when perl is embedded in some other program,
where output to STDOUT and STDERR may have to be redirected in some
sub PRINT { $r = shift; $$r++; print join($,,map(uc($_),@_)),$\ }
+=item READ this LIST
+
+This method will be called when the handle is read from via the C<read>
+or C<sysread> functions.
+
+ sub READ {
+ $r = shift;
+ my($buf,$len,$offset) = @_;
+ print "READ called, \$buf=$buf, \$len=$len, \$offset=$offset";
+ }
+
=item READLINE this
-This method will be called when the handle is read from. The method
-should return undef when there is no more data.
+This method will be called when the handle is read from via <HANDLE>.
+The method should return undef when there is no more data.
sub READLINE { $r = shift; "PRINT called $$r times\n"; }
+=item GETC this
+
+This method will be called when the C<getc> function is called.
+
+ sub GETC { print "Don't GETC, Get Perl"; return "a"; }
+
=item DESTROY this
As with the other types of ties, this method will be called when the
=item Compilation Option: Binary Compatibility With 5.003
-=item New Opcode Module and Revised Safe Module
+=item Subroutine Parameters Are Not Autovivified
=item Fixed Parsing of $$<digit>, &$<digit>, etc.
=item Changes to Tainting Checks
+=item New Opcode Module and Revised Safe Module
+
=item Internal Change: FileHandle Class Based on IO::* Classes
=item Internal Change: PerlIO internal IO abstraction interface
=item TIEHANDLE Now Supported
-TIEHANDLE classname, LIST, PRINT this, LIST, READLINE this, DESTROY this
+TIEHANDLE classname, LIST, PRINT this, LIST, READ this LIST, READLINE this,
+GETC this, DESTROY this
=item Malloc Enhancements
--DEMERGENCY_SBRK, -DPACK_MALLOC, -DTWO_POT_OPTIMIZE
+-DDEBUGGING_MSTATS, -DEMERGENCY_SBRK, -DPACK_MALLOC, -DTWO_POT_OPTIMIZE
=item Miscellaneous Efficiency Enhancements
=item Tying FileHandles
-TIEHANDLE classname, LIST, PRINT this, LIST, READLINE this, DESTROY this
+TIEHANDLE classname, LIST, PRINT this, LIST, READ this LIST, READLINE this,
+GETC this, DESTROY this
=item The C<untie> Gotcha
=item Subroutine, Signal, Sorting Traps
-Subroutine calls provide lvalue context to arguments, (Signals), (Sort
-Subroutine), warn() won't let you specify a filehandle
+(Signals), (Sort Subroutine), warn() won't let you specify a filehandle
=item OS Traps
=item Scratchpads
-=item Scratchpads and recursions
+=item Scratchpads and recursion
=back
=head1 AUTHOR
-Larry Wall E<lt>F<larry@wall.org>E<gt>, with the help of oodles
+Larry Wall <F<larry@wall.org>>, with the help of oodles
of other folks.
=over 5
-=item * Subroutine calls provide lvalue context to arguments
-
-Beginning with version 5.002, all subroutine arguments are consistently
-given a "value may be modified" context, since all subroutines are able
-to modify their arguments by explicitly referring to C<$_[0]> etc.
-This means that any array and hash elements provided as arguments
-will B<always be created> if they did not exist at the time
-the subroutine is called. (perl5 versions before 5.002 used to provide
-lvalue context for the second and subsequent arguments, and perl4 did
-not provide lvalue context to subroutine arguments at all--even though
-arguments were supposedly modifiable in perl4).
-
- sub test { $_[0] = 1; $_[1] = 2; $_[2] = 3; }
- &test($foo{'bar'}, $bar{'foo'}, $foo[5]);
- print join(':', %foo), '|', join(':',%bar), '|', join(':',@foo);
-
- # perl4 prints: ||
- # perl5 < 5.002 prints: |foo:2|:::::3
- # perl5 >= 5.002 prints: bar:1|foo:2|:::::3
-
=item * (Signals)
Barewords that used to look like strings to Perl will now look like subroutine
{
dSP; dTARGET;
GV *gv;
+ MAGIC *mg;
if (MAXARG <= 0)
gv = stdingv;
gv = (GV*)POPs;
if (!gv)
gv = argvgv;
+
+ if (SvMAGICAL(gv) && (mg = mg_find((SV*)gv, 'q'))) {
+ PUSHMARK(SP);
+ XPUSHs(mg->mg_obj);
+ PUTBACK;
+ ENTER;
+ perl_call_method("GETC", GIMME);
+ LEAVE;
+ SPAGAIN;
+ if (GIMME == G_SCALAR)
+ SvSetSV_nosteal(TARG, TOPs);
+ RETURN;
+ }
if (!gv || do_eof(gv)) /* make sure we have fp with something */
RETPUSHUNDEF;
TAINT;
Sock_size_t bufsize;
SV *bufsv;
STRLEN blen;
+ MAGIC *mg;
gv = (GV*)*++MARK;
+ if (SvMAGICAL(gv) && (mg = mg_find((SV*)gv, 'q'))) {
+ SV *sv;
+
+ PUSHMARK(MARK-1);
+ *MARK = mg->mg_obj;
+ ENTER;
+ perl_call_method("READ", G_SCALAR);
+ LEAVE;
+ SPAGAIN;
+ sv = POPs;
+ SP = ORIGMARK;
+ PUSHs(sv);
+ RETURN;
+ }
+
if (!gv)
goto say_undef;
bufsv = *++MARK;
OP* block_end _((I32 floor, OP* seq));
int block_start _((int full));
void boot_core_UNIVERSAL _((void));
-void calllist _((AV* list));
+void calllist _((I32 oldscope, AV* list));
I32 cando _((I32 bit, I32 effective, struct stat* statbufp));
#ifndef CASTNEGFLOAT
U32 cast_ulong _((double f));
use Config;
if ( ($Config{'cppstdin'} =~ /\bcppstdin\b/) and
- ( ! -x $Config{'scriptdir'} . "/cppstdin") ) {
+ ( ! -x $Config{'binexp'} . "/cppstdin") ) {
print "1..0\n";
exit; # Cannot test till after install, alas.
}
}
sub DESTROY {
print "and destroyed as well\n";
- }
+ }
+ sub READ {
+ shift;
+ print STDOUT "foo->can(READ)(@_)\n";
+ return 100;
+ }
+ sub GETC {
+ shift;
+ print STDOUT "Don't GETC, Get Perl\n";
+ return "a";
+ }
}
{
local(*FOO);
tie(*FOO,'foo');
print FOO "sentence.", "reversed", "a", "is", "This";
print "-- ", <FOO>, " --\n";
+ my($buf,$len,$offset);
+ $buf = "string";
+ $len = 10; $offset = 1;
+ read(FOO, $buf, $len, $offset) == 100 or die "foo->READ failed";
+ getc(FOO) eq "a" or die "foo->GETC failed";
}
EXPECT
This is a reversed sentence.
-- Out of inspiration --
+foo->can(READ)(string 10 1)
+Don't GETC, Get Perl
and destroyed as well
########
my @a; $a[2] = 1; for (@a) { $_ = 2 } print "@a\n"
* when Perl is built. Please do not change it by hand; make
* any changes to FndVers.Com instead.
*/
-#define ARCHLIB_EXP "/perl_root/lib/VMS_VAX/5_00392" /**/
+#define ARCHLIB_EXP "/perl_root/lib/VMS_VAX/5_00393" /**/
#define ARCHLIB ARCHLIB_EXP /*config-skip*/
/* ARCHNAME:
* This symbol holds the path of the bin directory where the package will
* be installed. Program must be prepared to deal with ~name substitution.
*/
+/* BIN_EXP:
+ * This symbol is the filename expanded version of the BIN symbol, for
+ * programs that do not want to deal with that at run-time.
+ */
#define BIN "/perl_root/000000" /**/
+#define BIN_EXP "/perl_root/000000" /**/
/* HAS_ALARM:
* This symbol, if defined, indicates that the alarm routine is
#define SITEARCH_EXP "/perl_root/lib/site_perl/VMS_VAX" /**/
#define SITEARCH SITEARCH_EXP /*config-skip*/
-/* SCRIPTDIR:
- * This symbol holds the name of the directory in which the user wants
- * to put publicly executable scripts for the package in question. It
- * is often a directory that is mounted across diverse architectures.
- * Programs must be prepared to deal with ~name expansion.
- */
-#define SCRIPTDIR "/perl_root/script" /**/
-
/* Size_t:
* This symbol holds the type used to declare length parameters
* for string functions. It is usually size_t, but may be
.endif
# Updated by fndvers.com -- do not edit by hand
-PERL_VERSION = 5_00392#
+PERL_VERSION = 5_00393#
ARCHDIR = [.lib.$(ARCH).$(PERL_VERSION)]
@ @[.vms]fndvers.com "" "" "[.vms]descrip.mms"
@ If F$TrnLnm("Sys").eqs."" Then Define/NoLog SYS GNU_CC_Include:[VMS]
CC = gcc
+PIPES_BROKEN = 1
# -fno-builtin avoids bug in gcc up to version 2.6.2 which can destroy
# data when memcpy() is called on large (>64 kB) blocks of memory
# (fixed in gcc 2.6.3)
-XTRACCFLAGS = /Obj=$(MMS$TARGET_NAME)$(O)/NoCase_Hack/Optimize=2/CC1="""""-fno-builtin"""""
+XTRACCFLAGS = /Obj=$(MMS$TARGET_NAME)$(O)/NoCase_Hack/Optimize=2
DBGSPECFLAGS =
XTRADEF = ,GNUC_ATTRIBUTE_CHECK
XTRAOBJS =
$(XSUBPP) $(MMS$SOURCE) >$(MMS$TARGET)
[.ext.dynaloader]dl_vms$(O) : [.ext.dynaloader]dl_vms.c
- $(CC) $(CFLAGS) /Object=$(MMS$TARGET) $(MMS$SOURCE)
+ $(CC) $(CFLAGS) /Include=([],[.ext.dynaloader])/Object=$(MMS$TARGET) $(MMS$SOURCE)
[.lib]DynaLoader.pm : [.ext.dynaloader]dynaloader.pm
Copy/Log/NoConfirm [.ext.dynaloader]dynaloader.pm [.lib]DynaLoader.pm
Link $(LINKFLAGS) /Exe=$(MMS$TARGET) $(MMS$SOURCE_LIST) $(CRTLOPTS)
# Accomodate buggy cpp in some version of DECC, which chokes on illegal
-# filespec "y.tab.c"
+# filespec "y.tab.c", and broken gcc cpp, which doesn't start #include ""
+# search in same dir as source file
[.x2p]a2p$(O) : [.x2p]a2p.c $(MINIPERL_EXE)
$(MINIPERL) -pe "s/^#line\s+(\d+)\s+\Q""y.tab.c""/#line $1 ""y_tab.c""/;" $(MMS$SOURCE) >$(MMS$TARGET_NAME)_vms.c
- $(CC) $(CFLAGS) /Object=$(MMS$TARGET) $(MMS$TARGET_NAME)_vms.c
+ $(CC) $(CFLAGS) /Object=$(MMS$TARGET)/Include=([.x2p],[]) $(MMS$TARGET_NAME)_vms.c
Delete/Log/NoConfirm $(MMS$TARGET_NAME)_vms.c;
+# gcc cpp broken -- doesn't look in directory of source file for #include ""
+.ifdef GNUC
+[.x2p]hash$(O) : [.x2p]hash.c
+ $(CC) $(CFLAGS) /Include=[.x2p] $(MMS$SOURCE)
+
+[.x2p]str$(O) : [.x2p]str.c
+ $(CC) $(CFLAGS) /Include=[.x2p] $(MMS$SOURCE)
+
+[.x2p]util$(O) : [.x2p]util.c
+ $(CC) $(CFLAGS) /Include=[.x2p] $(MMS$SOURCE)
+
+[.x2p]walk$(O) : [.x2p]walk.c
+ $(CC) $(CFLAGS) /Include=[.x2p] $(MMS$SOURCE)
+.endif
+
[.lib.pod]pod2html.com : [.pod]pod2html.PL $(ARCHDIR)Config.pm
@ If F$Search("[.lib]pod.dir").eqs."" Then Create/Directory [.lib.pod]
$(MINIPERL) $(MMS$SOURCE)
[.x2p]str$(O) : [.x2p]str.h
[.x2p]str$(O) : handy.h
[.x2p]str$(O) : [.x2p]util.h
+.ifdef __MMK__
[.x2p]util$(O) : [.x2p]util.c
+.endif
[.x2p]util$(O) : [.x2p]EXTERN.h
[.x2p]util$(O) : [.x2p]a2p.h
[.x2p]util$(O) : [.x2p]hash.h
# if DOINIT is #defined. Bleah. It's cheaper to just add
# it by hand than to add /Define=DOINIT to the preprocessing
# run and wade through all the extra junk.
- $vars{'Error'}++;
+ $vars{"${embed}Error"}++;
}
# Eventually, we'll check against existing copies here, so we can add new
#include <in.h>
#include <inet.h>
#include <netdb.h>
-/* However, we don't have these two in the system headers. */
-void setnetent(int);
-void endnetent();
/* SocketShr doesn't support these routines, but the DECC RTL contains
* stubs with these names, designed to be used with the UCX socket
#define endnetent no_endnetent
#endif
+/* We don't have these two in the system headers. */
+void setnetent(int);
+void endnetent();
+
#include <socketshr.h>
/* socketshr.h from SocketShr 0.9D doesn't alias fileno; its comments say
* that the CRTL version works OK. This isn't the case, at least with
* This symbol holds the path of the bin directory where the package will
* be installed. Program must be prepared to deal with ~name substitution.
*/
+/* BIN_EXP:
+ * This symbol is the filename expanded version of the BIN symbol, for
+ * programs that do not want to deal with that at run-time.
+ */
#define BIN "/usr/local/bin" /**/
+#define BIN_EXP "/usr/local/bin" /**/
/* CAT2:
* This macro catenates 2 tokens together.
*/
#define RANDBITS 15 /**/
-/* SCRIPTDIR:
- * This symbol holds the name of the directory in which the user wants
- * to put publicly executable scripts for the package in question. It
- * is often a directory that is mounted across diverse architectures.
- * Programs must be prepared to deal with ~name expansion.
- */
-#define SCRIPTDIR "/usr/local/script" /**/
-
/* Select_fd_set_t:
* This symbol holds the type used for the 2nd, 3rd, and 4th
* arguments to select. Usually, this is 'fd_set *', if HAS_FD_SET