Bug#1043234: libmath-bigint-perl: subclassing breaks numeric comparison

2023-08-10 Thread Niko Tyni
Control: forwarded -1 https://github.com/pjacklam/p5-Math-BigInt/issues/8
Control: tag -1 patch
Control: affects -1 libpgobject-type-bigfloat-perl

On Mon, Aug 07, 2023 at 08:06:09PM +0100, Niko Tyni wrote:
> Package: libmath-bigint-perl
> Version: 1.999838-1
> Severity: important
> Tags: ftbfs upstream
> User: debian-p...@lists.debian.org
> Usertags: perl-5.38-transition
> Control: affects -1 ledgersmb

> I was able to narrow it down to this test, which fails with newer versions:
> 
> ---
> package MyFloat;
> use base qw(Math::BigFloat);
> 1;
> 
> print MyFloat->new(.99) == Math::BigFloat->new(.99) ? "ok\n": "not 
> ok\n";
> ---
> 
> It bisects down to upstream commit 
> 
>   
> https://github.com/pjacklam/p5-Math-BigInt/commit/46d1252c98f565ae787c840173e5f98acf8953f1
> 
> so it regressed with upstream version 1.999836.

I've filed an upstream bug at 
https://github.com/pjacklam/p5-Math-BigInt/issues/8
and sent a proposed patch at  https://github.com/pjacklam/p5-Math-BigInt/pull/9

-- 
Niko



Bug#1043234: libmath-bigint-perl: subclassing breaks numeric comparison

2023-08-07 Thread Niko Tyni
Package: libmath-bigint-perl
Version: 1.999838-1
Severity: important
Tags: ftbfs upstream
User: debian-p...@lists.debian.org
Usertags: perl-5.38-transition
Control: affects -1 ledgersmb

ledgersmb fails to build with new versions of Math-BigInt,
including the one separately packaged (both in stable and unstable)
as libmath-bigint-perl, and the one bundled with Perl 5.38 (currently
in experimental.)

   #   Failed test 'form: 9.999,99 parsed as 1.000,00 - .99'
   #   at t/02-number-handling.t line 224.
   #  got: .99
   # expected: .99
   
   [...]
   
   Test Summary Report
   ---
   t/02-number-handling.t(Wstat: 5120 (exited 20) Tests: 374 Failed: 20)
 Failed tests:  336-340, 345-349, 354-358, 365-369
 Non-zero exit status: 20
   Files=20, Tests=1802, 17 wallclock secs ( 0.39 usr  0.06 sys + 14.92 cusr  
1.89 csys = 17.26 CPU)
   Result: FAIL

I was able to narrow it down to this test, which fails with newer versions:

---
package MyFloat;
use base qw(Math::BigFloat);
1;

print MyFloat->new(.99) == Math::BigFloat->new(.99) ? "ok\n": "not 
ok\n";
---

It bisects down to upstream commit 

  
https://github.com/pjacklam/p5-Math-BigInt/commit/46d1252c98f565ae787c840173e5f98acf8953f1

so it regressed with upstream version 1.999836.
-- 
Niko Tyni   nt...@debian.org