GCC 2.95.2 rozdily proti egcs 1.91.66 na RH 6.1

Petr Novotny Petr.Novotny na antek.cz
Pondělí Květen 15 10:03:57 CEST 2000


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 13 May 00, at 21:33, Pavel Kankovsky wrote:

> Implicitni destruktory? Ony existuji nejake explicitni destruktory? :)

Co treba takhle:
class A {
public:
A();
A(const A&);
~A();
const A &operator=(const A&);
...
};

const A &A::operator=(const A&other)
{
  this->A::~A();
  this->A::A(other);
  return *this;
}

Quick-and-dirty, lec funkcni (aspon na C++, s nimiz jsem 
pracoval). Nesmi se zapomenout ani na this->, ani na A:: (v 
druhem pripade se to neprelozi, v prvnim pripade to ma tendenci 
pracovat s automatickou (novou) instanci A na stacku).

-----BEGIN PGP SIGNATURE-----
Version: PGP 6.0.2 -- QDPGP 2.60 
Comment: http://community.wow.net/grt/qdpgp.html

iQA/AwUBOR+hXVMwP8g7qbw/EQIfgACg/UMcESsaV97G0Um9XgdVt1fQdu8An0GE
0FGn/Z8grC8V0Vr43AWRvoLB
=7u0J
-----END PGP SIGNATURE-----
--
Petr Novotny, ANTEK CS
Petr.Novotny na antek.cz
http://www.antek.cz
PGP key ID: 0x3BA9BC3F
-- Don't you know there ain't no devil there's just God when he's drunk.
                                                             [Tom Waits]


Další informace o konferenci Linux