| Server IP : 127.0.0.1 / Your IP : 216.73.216.48 Web Server : Apache/2.4.58 (Win64) OpenSSL/3.1.3 PHP/8.2.12 System : Windows NT DESKTOP-3H4FHQJ 10.0 build 19045 (Windows 10) AMD64 User : win 10 ( 0) PHP Version : 8.2.12 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : D:/xampp/perl/vendor/lib/Math/Int64/ |
Upload File : |
package Math::Int64::die_on_overflow;
use strict;
use warnings;
use Math::Int64 ();
sub import {
require Math::Int64;
Math::Int64::_set_may_die_on_overflow(1);
$^H{'Math::Int64::die_on_overflow'} = 1;
goto &Math::Int64::_check_pragma_compatibility;
}
sub unimport {
undef $^H{'Math::Int64::die_on_overflow'}
}
1;
# ABSTRACT: catch overflows when using Math::Int64
__END__
=encoding UTF-8
=head1 NAME
Math::Int64::die_on_overflow - catch overflows when using Math::Int64
=head1 SYNOPSIS
use Math::Int64 qw(uint64);
use Math::Int64::die_on_overflow;
my $number = uint64(2**32);
say($number * $number); # overflow error!
=head1 SEE ALSO
L<Math::Int64>.
=cut