testRoundTripFuzzPow failed on CI for #274 (run https://github.com/rainlanguage/rain.math.float/actions/runs/34196695194) with a Panic(0x11) from the first pow leg. It reproduces on main (b6eba33) with the counterexample, so it is independent of that PR.
Behaviour: LibDecimalFloat.pow(a, b, tables) reverts with a raw arithmetic overflow panic instead of one of the typed errors pow is designed to throw (ExponentOverflow / ExponentUnderflow / WithTargetExponentOverflow / MaximizeOverflow / MulDivOverflow / ZeroNegativePower / PowNegativeBase). The test's own contract is that a Panic is a failure, not a swallowed revert.
Repro (any LogTest subclass):
Float a = Float.wrap(0x5061727365206572726f7220286e656729000000000000000000000000000000);
// coefficient 10649868514120859750743193552471890618207833841010459988146104827904, exponent 1348563571
Float b = Float.wrap(0x00000003b58e88c75313ec9d329eaaa18fb92f75215b170fffffffffffffffff);
// coefficient -7839786668602559178668060348078522694548577690162289924414440996865, exponent 3
a.pow(b, logTables()); // reverts 0x4e487b71…11
log10(a) is about 1.35e9 and b about -7.8e69, so the intermediate b * log10(a) and the pow10 of it are far outside any representable exponent. Somewhere on that path a checked int operation overflows before the typed exponent checks run. Expected: ExponentUnderflow (or another typed error). Triage question: which operation, and whether the typed check should come first or the arithmetic should saturate.
testRoundTripFuzzPowfailed on CI for #274 (run https://github.com/rainlanguage/rain.math.float/actions/runs/34196695194) with aPanic(0x11)from the firstpowleg. It reproduces onmain(b6eba33) with the counterexample, so it is independent of that PR.Behaviour:
LibDecimalFloat.pow(a, b, tables)reverts with a raw arithmetic overflow panic instead of one of the typed errorspowis designed to throw (ExponentOverflow/ExponentUnderflow/WithTargetExponentOverflow/MaximizeOverflow/MulDivOverflow/ZeroNegativePower/PowNegativeBase). The test's own contract is that aPanicis a failure, not a swallowed revert.Repro (any
LogTestsubclass):log10(a)is about 1.35e9 andbabout -7.8e69, so the intermediateb * log10(a)and thepow10of it are far outside any representable exponent. Somewhere on that path a checkedintoperation overflows before the typed exponent checks run. Expected:ExponentUnderflow(or another typed error). Triage question: which operation, and whether the typed check should come first or the arithmetic should saturate.