This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Convert Math::BigInt::FastCalc to XSLoader.
authorNicholas Clark <nick@ccl4.org>
Mon, 25 Oct 2010 09:09:09 +0000 (10:09 +0100)
committerNicholas Clark <nick@ccl4.org>
Mon, 25 Oct 2010 09:12:29 +0000 (10:12 +0100)
As the minimum perl version is 5.006, enable 'use warnings'.

dist/Math-BigInt-FastCalc/FastCalc.pm

index 03af519..24ab90b 100644 (file)
@@ -2,18 +2,16 @@ package Math::BigInt::FastCalc;
 
 use 5.006;
 use strict;
 
 use 5.006;
 use strict;
-# use warnings;        # dont use warnings for older Perls
+use warnings;
 
 
-use DynaLoader;
 use Math::BigInt::Calc;
 
 use Math::BigInt::Calc;
 
-use vars qw/@ISA $VERSION $BASE $BASE_LEN/;
-
-@ISA = qw(DynaLoader);
+use vars qw/$VERSION $BASE $BASE_LEN/;
 
 $VERSION = '0.23';
 
 
 $VERSION = '0.23';
 
-bootstrap Math::BigInt::FastCalc $VERSION;
+require XSLoader;
+XSLoader::load(__PACKAGE__);
 
 ##############################################################################
 # global constants, flags and accessory
 
 ##############################################################################
 # global constants, flags and accessory