Package: perl
Version: 5.8.8-7etch1
Followup-For: Bug #469402
The text I'm confused by is:
The following triples are more or less equivalent:
open(FOO, "|tr '[a-z]' '[A-Z]'");
open(FOO, '|-', "tr '[a-z]' '[A-Z]'");
open(FOO, '|-') || exec 'tr', '[a-z]', '[A-Z]';
open(FOO, '|-', "tr", '[a-z]', '[A-Z]');
open(FOO, "cat -n '$file'|");
open(FOO, '-|', "cat -n '$file'");
open(FOO, '-|') || exec 'cat', '-n', $file;
open(FOO, '-|', "cat", '-n', $file);
The last example in each block shows the pipe as "list form",
which is not yet supported on all platforms. A good rule of
thumb is that if your platform has true "fork()" (in other words,
if your platform is UNIX) you can use the list form.
The reason I'm confused is that I'm trying to write some Perl that works
on Debian and Windows, and I find that none of the last three forms
seems to work on Windows (with ActiveState Perl, I get:
'-' is not recognized as an internal or external command,
operable program or batch file.
Two problems with the man page (I'm not expecting you to solve my
Windows woes, of course!):
1. It's not clear whether, having presumably had only 3 examples in each
block before, "last" really means "last", or whether it means "3rd" or
"3rd and 4th". I can't tell.
2. Is the reason that open '-|' doesn't work on Windows because it
doesn't have fork? In that case, presumably the warning needs to apply
to the 2nd-4th code examples in each block. If not, then another
warning/reminder is needed that for some other reason some of the
examples won't work anyway on some platforms.
This is more of an upstream than Debian problem so please feel free to
just chuck it straight upstream.
-- System Information:
Debian Release: 4.0
APT prefers stable
APT policy: (700, 'stable')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-5-k7
Locale: LANG=en_GB, LC_CTYPE=en_GB (charmap=ISO-8859-1)
Versions of packages perl depends on:
ii libc6 2.3.6.ds1-13etch5 GNU C Library: Shared libraries
ii libdb4.4 4.4.20-8 Berkeley v4.4 Database Libraries [
ii libgdbm3 1.8.3-3 GNU dbm database routines (runtime
ii perl-base 5.8.8-7etch1 The Pathologically Eclectic Rubbis
ii perl-modules 5.8.8-7etch1 Core Perl modules
Versions of packages perl recommends:
ii perl-doc 5.8.8-7etch1 Perl documentation
-- no debconf information
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]