[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]
Re: $VERSION in Opcode
Matt S Trout wrote:
> I'd still really like a way to get at your (rather good) version comparison
> stuff without mucking with UNIVERSAL - would you take a patch to allow
> something like "use version::no_universal" or something?
I'd rather know what usage of MODULE->VERSION doesn't work for you (as I worked
rather hard to make UNIVERSAL::VERSION DTRT). It may be that I did something
stupid or it may be that you are doing something stupid; either way, I would
rather fix that problem rather than papering over it. ;-)
> (and also, mutter grumble mutter it's -still- not a bloody pragma mutter :)
Although most are, all pragmas are not necessarily lexical (see 'constant' or
'lib' for example). A pragma is merely a way of affecting *at compile-time* how
Perl operates, and they can have run-time effects as well (as does version.pm).
The very nature of version.pm requires it to be global in nature because the
CPAN release is designed to make [very] old Perl's work exactly like the latest
Perl (5.10.0) when it comes to version comparisons. Specifically, if you don't
have the upgraded UNIVERSAL::VERSION, certain $VERSION strings that would be
equivalent otherwise will show up as different.
John
- Follow-Ups from:
-
Matt S Trout <mtt-p5p@trout.me.uk>
[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]