Skip Menu |

This queue is for tickets about the File-Remove CPAN distribution.

Report information
The Basics
Id: 16792
Status: resolved
Priority: 0/
Queue: File-Remove

People
Owner: Nobody in particular
Requestors: adamk [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.31
Fixed in: (no value)



Subject: One "our" means everything that uses this needs 5.6.0
A ton of modules use File::Remove, including a bunch that are trying to be 5.005-dependant. File::Remove isn't compatible with 5.005 at the moment. According to perlver it needs 5.6.0 due to a single "our" in the code. Could you convert it to a use vars, and add a use 5.whatever to the top of the module so we know what the minimum perl version should be. Also, you might want to consider doing a quick upgrade of the Makefile.PL to Module::Install, which will help propogate this information to other places.
[ADAMK - Thu Dec 29 14:40:22 2005]: Show quoted text
> A ton of modules use File::Remove, including a bunch that are trying > to be 5.005-dependant. File::Remove isn't compatible with 5.005 at > the moment. According to perlver it needs 5.6.0 due to a single > "our" in the code.
There are 3 uses of it in the code; one top-level and two in &trash. Show quoted text
> Could you convert it to a use vars, and add a use 5.whatever to the > top of the module so we know what the minimum perl version should > be.
I have removed the easy one (our $glue). Having little experience with our(), the two occurences of it in &trash appear to be our() as a result of trying to temporarily modify globals before a goto. How would you suggest they be corrected without breaking &trash? - R.
Show quoted text
> I have removed the easy one (our $glue). Having little experience with > our(), the two occurences of it in &trash appear to be our() as a result > of trying to temporarily modify globals before a goto. How would you > suggest they be corrected without breaking &trash?
Weird... our $foo = $foo? I would have thought that local $foo = $foo; would do the same thing. in fact, I'd think instead of our $foo = $foo, you might want to do something more like... sub ... { my ($_unlink, $_rmdir); if ( ... ) { $_unlink = ...; } else { ... and so on } local $unlink = $_unlink; local $rmdir = $_rmdir; goto ...; }