Work around clang bug.

https://godbolt.org/z/zedh7rrhc

This is similar to https://github.com/llvm/llvm-project/issues/47746,
except I needed to use a different workaround.
This commit is contained in:
Lenard Szolnoki 2023-03-04 23:02:15 +00:00
parent 6732e397d8
commit e05858a0f8

View File

@ -594,7 +594,12 @@ struct bigint : pow5_tables<> {
exp -= small_step;
}
if (exp != 0) {
FASTFLOAT_TRY(small_mul(vec, limb(small_power_of_5[exp])));
// Work around clang bug https://godbolt.org/z/zedh7rrhc
// This is similar to https://github.com/llvm/llvm-project/issues/47746,
// except the workaround described there don't work here
FASTFLOAT_TRY(
small_mul(vec, limb(((void)small_power_of_5[0], small_power_of_5[exp])))
);
}
return true;