HEX
Server: Apache
System: Linux box5514.bluehost.com 5.14.0-162.23.1.9991722448259.nf.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jul 31 18:11:45 UTC 2024 x86_64
User: smqcdvmy (3893)
PHP: 8.3.30
Disabled: NONE
Upload Files
File: //lib64/perl5/vendor_perl/Math/Int64/die_on_overflow.pm
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