1
Apakah ini bug di std :: gcd?
Saya menemukan perilaku std::gcdyang tidak terduga ini: #include <iostream> #include <numeric> int main() { int a = -120; unsigned b = 10; //both a and b are representable in type C using C = std::common_type<decltype(a), decltype(b)>::type; C ca = std::abs(a); C cb = b; std::cout << a << ' ' …