Add C++ comparison function for floating point/complex scalar/arrays