http://d.puremagic.com/issues/show_bug.cgi?id=6560



--- Comment #4 from bdsat...@gmail.com 2011-08-27 03:00:15 PDT ---
(In reply to comment #3)
> The deprecation of the built-in complex numbers will cause the deprecation of
> their nice literals too. This means in your program you are not really using
> the std.complex module. 
Looks like D is going in the wrong direction. IIUC, there is no longer a
builtin imaginary type. D1 agrees with Prof. Kahan but D2 diverges so that it
can introduce inadvertent errors
(http://www.digitalmars.com/d/2.0/cppcomplex.html). 

> You have to write it this way:
> 
> import std.stdio, std.complex;
> 
> void main() {
>     writeln(complex(1, 3) ^^ complex(4, 6));
> }

The above program gives an error:

complexes.d(6): Error: undefined identifier complex, did you mean struct
Complex(T) if (isFloatingPoint!(T))?
complexes.d(6): Error: undefined identifier complex, did you mean struct
Complex(T) if (isFloatingPoint!(T))?

I thought 1,3, etc. are integers, may be, so changing 1 -> 1.0, 3 -> 3.0 etc.
it still gives same error.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to