develooper Front page | perl.perl5.porters | Postings from August 2001

Re: [PATCH 2 of 3] $] is deprecated - EXTERMINATE, EXTERMINATE, EXTERMINATE

Thread Previous | Thread Next
From:
John Peacock
Date:
August 23, 2001 07:09
Subject:
Re: [PATCH 2 of 3] $] is deprecated - EXTERMINATE, EXTERMINATE, EXTERMINATE
Message ID:
3B850E5B.7D0A5D5D@rowman.com
Ronald J Kimball wrote:
> 
> Keep in mind that $^V is not directly printable.  This should probably be
> something like
> 
> ok 26, $^V ge 5.3.190, join('.', unpack 'C*', $^V)
> 
> except, of course, that this won't do the right thing for subversions
> greater than 255.  (Have I mentioned lately how much I dislike version
> strings?)
> 
> Ronald

Doh.  I guess I need to take up coffee drinking, since I am obviously 
not awake yet this morning.  How about this:

$ diff -wruN perl/t/op/magic.t.orig perl/t/op/magic.t
--- perl/t/op/magic.t.orig      Thu Aug 23 09:06:48 2001
+++ perl/t/op/magic.t   Thu Aug 23 10:04:28 2001
@@ -182,8 +182,8 @@
     ok 25, unlink($script), $!;
 }

-# $], $^O, $^T
-ok 26, $] >= 5.00319, $];
+# $^V, $^O, $^T
+ok 26, $^V ge 5.3.190, sprintf("%vd",$^V);
 ok 27, $^O;
 ok 28, $^T > 850000000, $^T;

NOTE: you are probably going to HATE the patches I am going to send 
making v-strings be the preferred method for storing version strings.
:~(

John

--
John Peacock
Director of Information Research and Technology
Rowman & Littlefield Publishing Group
4720 Boston Way
Lanham, MD 20706
301-459-3366 x.5010
fax 301-429-5747

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About