Compiler error CS0029: "if (int & int)"
Adapt the old code to C + + The compiler does not pass an expression like "if (a and b)"
int a = 32;
int b = 1;
if (a & b) {} <--- Compiler Error
Implicit conversion from Int to Bool. I can change to if ((a & b)! = 0) {}
But it is worse to read and find in many places.
Is there a way to get around this?
+3
source to share