Closed p5pRT closed 21 years ago
The following prevents installation of perl when build with -Duselongdouble:
$ ./perl -wle 'print $]' %5.3llf $
On Mon\, Aug 28\, 2000 at 07:02:51AM -0000\, abigail@foad.org wrote:
The following prevents installation of perl when build with -Duselongdouble:
$ \./perl \-wle 'print $\]' %5\.3llf $
Here's a test that tests whether $] has an appropriate value:
Abigail
*** t/comp/use.t.orig Mon Aug 28 03:09:41 2000
--- t/comp/use.t Mon Aug 28 03:17:39 2000
***************
*** 5\,13 ****
unshift @INC\, '../lib';
}
! print "1..27\n";
my $i = 1;
eval "use 5.000"; # implicit semicolon
if ($@) {
print STDERR $@\,"\n";
--- 5\,31 ----
unshift @INC\, '../lib';
}
! print "1..28\n";
my $i = 1;
+
+ # Test for $];
+ if (open my $fh => "../patchlevel.h") {
+ my %parts;
+ while (\<$fh>) {
+ next unless /^#define\s+PERL_(REVISION|VERSION|SUBVERSION)\s+(\d+)/;
+ $parts {$1} = $2;
+ }
+ my $version = sprintf "%d.%03d" => @parts {qw /REVISION VERSION/};
+ $version .= sprintf "%02d" => $parts {SUBVERSION}
+ if $parts {SUBVERSION};
+ print "not " unless $] eq $version;
+ print "ok "\, $i ++\, "\n";
+ }
+ else {
+ print "ok "\, $i ++\, " # Skipped\, could not read ../patchlevel.h\n";
+ }
+
eval "use 5.000"; # implicit semicolon
if ($@) {
print STDERR $@\,"\n";
On Mon\, Aug 28\, 2000 at 03:32:54AM -0400\, abigail@foad.org wrote:
On Mon\, Aug 28\, 2000 at 07:02:51AM -0000\, abigail@foad.org wrote:
The following prevents installation of perl when build with -Duselongdouble:
$ \./perl \-wle 'print $\]' %5\.3llf $
Here's a test that tests whether $] has an appropriate value:
Hmmm\, wouldn't fixing the printing of $] be more valuable?
Migrated from rt.perl.org#3901 (status was 'resolved')
Searchable as RT3901$