1 // cl_N equal_hashcode().
7 #include "cln/complex.h"
18 uint32 equal_hashcode (const cl_N& x)
22 return equal_hashcode(x);
25 var const cl_R& a = realpart(x);
26 var const cl_R& b = imagpart(x);
27 var uint32 code1 = equal_hashcode(a);
28 var uint32 code2 = equal_hashcode(b);
29 // Wichtig beim Kombinieren, wegen "complex canonicalization":
30 // Ist imagpart=0.0, so ist der Hashcode = equal_hashcode(a).
31 return code1 ^ ((code2 << 5) | (code2 >> 27));