develooper Front page | perl.perl5.porters | Postings from January 2009

Re: [PATCH] Re: [PATCH] File::Copy & permission bits.

Thread Previous | Thread Next
Nicholas Clark
January 28, 2009 07:30
Re: [PATCH] Re: [PATCH] File::Copy & permission bits.
Message ID:
On Sat, Jan 24, 2009 at 11:11:08PM -0500, Charles Bailey wrote:

> - Moves the permission-changing code to File::Copy::cp(), making it
> non-identical to File::Copy::copy().  I think this is a decent
> compromise, retaining backwards compatibility in the "primary"
> routine, while allowing people who chose cp() to get more POSIXy
> semantics.  It does break backwards compatibility of cp() wrt
> permissions.  I can find a handful of examples in CPAN, for which I
> hope smokers will give some feedback.  As for the DARKpan, who knows .
> . .

Although it's starting to sound like this should be in syscopy, not cp.
syscopy is currently documented as

    File::Copy also provides the C<syscopy> routine, which copies the
    file specified in the first parameter to the file specified in the
    second parameter, preserving OS-specific attributes and file
    structure.  For Unix systems, this is equivalent to the simple
    C<copy> routine, which doesn't preserve OS-specific attributes.  For
    VMS systems, this calls the C<rmscopy> routine (see below).  For OS/2
    systems, this calls the C<syscopy> XSUB directly. For Win32 systems,
    this calls C<Win32::CopyFile>.

Removing the "For Unix systems..." seems to be the least backwards
incompatible change of all proposed so far.

Nicholas Clark

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About