p4raw-id: //depot/perl@2914
/* FALL THROUGH */
case OP_SYSOPEN:
case OP_OPEN:
+ case OP_SELECT: /* XXX c.f. SelectSaver.pm */
case OP_SOCKET:
case OP_OPEN_DIR:
case OP_ACCEPT:
(F) This machine doesn't implement the select() system call.
-=item select() on unopened file
-
-(W) You tried to use the select() function on a filehandle that
-was either never opened or has since been closed.
-
=item sem%s not implemented
(F) You don't have System V semaphore IPC on your system.
}
if (newdefout) {
- if (!GvIO(newdefout)) {
- if (ckWARN(WARN_UNOPENED))
- warner(WARN_UNOPENED, "select() on unopened file");
- if (SvTYPE(newdefout) != SVt_PVGV)
- RETURN;
- gv_IOadd(newdefout); /* XXX probably bogus */
- }
+ if (!GvIO(newdefout))
+ gv_IOadd(newdefout);
setdefout(newdefout);
}
package X;
sub any { bless {} }
my $f = "FH000"; # just to thwart any future optimisations
-sub afh {
- open(++$f, '>&STDOUT') or die;
- select select $f;
- my $r = *{$f}{IO};
- delete $X::{$f};
- bless $r;
-}
+sub afh { select select ++$f; my $r = *{$f}{IO}; delete $X::{$f}; bless $r }
sub DESTROY { print "destroyed\n" }
package main;
$x = any X; # to bump sv_objcount. IO objs aren't counted??