I'm guessing M_PI is a double, or is defined with something like #define M_PI 3.13159
What you you are doing in myrobot.move(M_PI/2.0, 10.0) is converting a double to a float. That's going from a 64 bit number to a 32 bit number. You therefore lose precision. The you subtract the float from the double and you have a VERY small difference. That difference is attributed to the fact that we lost that much precision. In fact, depending on your warning level, the compiler is probably screaming out warnings at you.
As a general rule, never use the == operator on a floating point number (double or float) because it can become a VERY small number very fast without ever actually being exactly zero.