[Wow. This is the first time that I broke something in C++11 mode - I
didn't realize that I was still in C++98 mode when testing...]
Manually specify all products that shall be available in ProductType -
otherwise our overloads cannot be used.
typedef float type;
};
+#endif
+
+// Annoyingly, there is no std::complex<T>::operator*(U) for scalars U
+// other than T (not even in C++11, or C++14). We provide our own overloads
+// in base/complex_overloads.h, but in order for them to work, we have to
+// manually specify all products we want to allow:
+
template <typename T>
struct ProductType<std::complex<T>,std::complex<T> >
{
typedef std::complex<typename ProductType<T,float>::type> type;
};
-#endif
/**
In the beginning the Universe was created. This has made a lot of
people very angry and has been widely regarded as a bad move.
Douglas Adams