Skip Menu |

This queue is for tickets about the constant-lexical CPAN distribution.

Report information
The Basics
Id: 99908
Status: rejected
Priority: 0/
Queue: constant-lexical

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

Bug Information
Severity: Normal
Broken in: 2.0001
Fixed in: (no value)



Subject: Dependency on Sub::Delete is always there, no matter what perl version
The documentation states: This module requires perl 5.8.0 or later and, depending on your version of perl, one of the following modules, which you can get from the CPAN: For perl 5.11.2 and higher: Lexical::Sub For lower perl versions: Sub::Delete However, the code in lexical.pm has an unconditional 'use Sub::Delete;'. This means that Sub::Delete is always required, even if you are using perl 5.11.2 or later. Am I misinterpreting the documentation or should the hard dependency on Sub::Delete be changed to a conditional one depending on perl version? (An alternative, of course, would be to drop support for perl < 5.12.)
On Thu Oct 30 11:47:40 2014, EDAVIS wrote: Show quoted text
> The documentation states: > > This module requires perl 5.8.0 or later and, depending on your > version of perl, one of the following modules, which you can get from > the CPAN: > > For perl 5.11.2 and higher: Lexical::Sub > For lower perl versions: Sub::Delete > > However, the code in lexical.pm has an unconditional 'use > Sub::Delete;'. > This means that Sub::Delete is always required, even if you are using > perl > 5.11.2 or later. > > Am I misinterpreting the documentation or should the hard dependency > on > Sub::Delete be changed to a conditional one depending on perl version? > > (An alternative, of course, would be to drop support for perl < 5.12.)
I think you are missing the fact that the ‘use’ statement is inside a here-doc that evaluated just before __END__. It has been a while since I last worked on this code. Am I perhaps misreading my own code?