Define isnan() for C++98 compatibility