Compilation errors fixed.

This commit is contained in:
mlemanczyk committed 2025-10-12 00:37:57 +02:00
1 parent 4f73d89716
commit dde01cf8b9
2 files changed
+14 -21

No files matched your search

+2 -6
View File
@@ -347,14 +347,10 @@ public static class ULongExtensions
ulong result = divisor.MontgomeryOne;
ulong nPrime = divisor.NPrime;
Span<ulong> oddPowerStorage;
Span<ulong> oddPowerStorage = oddPowerCount <= PerfectNumberConstants.MaxOddPowersCount ? stackalloc ulong[PerfectNumberConstants.MaxOddPowersCount] : default;
ulong[]? pooledOddPowers = null;
if (oddPowerCount <= PerfectNumberConstants.MaxOddPowersCount)
{
oddPowerStorage = stackalloc ulong[PerfectNumberConstants.MaxOddPowersCount];
}
else if (oddPowerCount < PerfectNumberConstants.PooledArrayThreshold)
if (oddPowerCount < PerfectNumberConstants.PooledArrayThreshold)
{
oddPowerStorage = new ulong[oddPowerCount];
}