delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/05/15/03:46:39

Date: Mon, 15 May 2000 10:52:49 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: "Alexei A. Frounze" <alex DOT fru AT mtu-net DOT ru>
cc: djgpp AT delorie DOT com
Subject: Re: C++, complex, etc
In-Reply-To: <391F45A0.934B2428@mtu-net.ru>
Message-ID: <Pine.SUN.3.91.1000515105224.9209M-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Mon, 15 May 2000, Alexei A. Frounze wrote:

> I've found a strange solution...
> 
> Now my rpogram looks like:
> ------------8<-------------
> #include <iostream.h>
> #include <_Complex.h>

That's not a good solution: _Complex.h is a non-standard header from
libg++ distribution.  The libg++ classes are deprecated and should not
be used, especially in portable programs, as you yourself discovered:

> The source code is no more portable. 
> 
> Borland C/C++ doesn't have the "_Complex.h" header file and there is no
> class with name "Complex" in "complex.h".
> 
> Watcom C/C++ has no the "_Complex.h" header file but have a typedef that
> makes "complex" the same as "Complex".

> Please explain me the purpose of these include/header files from the
> "djgpp/lang/cxx" directory:

What do you need to know? <complex> defines the float_complex,
double_complex, and long_double_complex types, <complex.h> is an alias
for <complex> (kept for back-compatibility), and <_Complex.h>
(originally Complex.h) is the libg++-specific header that defines the
Complex type.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019