-
Notifications
You must be signed in to change notification settings - Fork 163
Closed
Labels
Description
After PR #685, a user setting CMake option DEFINE_ARITHMETIC_OVERLOADS
to OFF
will not only prevent the overloads in their own source (as intended), but also prevent them during compilation of the QuEST source. This crashes compilation since the source contains arithmetic between qcomp
and integer literals, like here:
QuEST/quest/src/core/localiser.cpp
Lines 1277 to 1278 in 2655690
qcomp fac0 = (isGadget)? std::exp(+ phase * sign * 1_i) : +1 * sign; | |
qcomp fac1 = (isGadget)? std::exp(- phase * sign * 1_i) : -1 * sign; |
Note that no issue has yet been witnessed from users being exposed to the relevant arithmetic overloads, and the original macro to disable it was hastily written just in case. As such, this bug is so incredibly important, and we might as well just delete DEFINE_ARITHMETIC_OVERLOADS
.