Community
Participate
Working Groups
The indexer fails on std::abs if the argument is a std::complex type. #include <algorithm> #include <cmath> #include <complex> int main() { float a = 1.0f, b = 2.0f; float c = 3.0f, d = 4.0f; { auto mag1 = std::abs(a); auto mag2 = std::abs(b); const auto min = std::min(mag1, mag2); } { auto mag1 = std::abs(std::complex(a, b)); // indexer: invalid arguments auto mag2 = std::abs(std::complex(c, d)); // indexer: invalid arguments auto min = std::min(mag1, mag2); // indexer: invalid arguments } } Environment: Linux with g++ 9.3
I guess the problem is not the indexer but the parser.