std.complex
Lars T. Kyllingstad
public at kyllingen.net
Wed Jan 1 14:46:59 PST 2014
On Tuesday, 19 November 2013 at 01:44:32 UTC, Craig Dillabaugh
wrote:
> The complex type in std.complex restricts the real/imaginary
> parts of the number to be float/double/real. I am curious to
> know if there is a reason why integral types are not permitted.
> I
> checked the C++ equivalent and it does not have the same
> requirement.
Quoting the C++ standard, §26.4:
"The effect of instantiating the template complex for any type
other than float, double, or long double is unspecified."
So even if some implementations support it, it is *not* standard
C++.
Lars
More information about the Digitalmars-d
mailing list