delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/06/13/16:49:26

From: Roberto Henriquez Laurent <shl24634 AT alumnos DOT inf-cr DOT uclm DOT es>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: copy constructor
Date: Wed, 11 Jun 1997 09:59:17 +0200
Organization: Universidad de Castilla-La Mancha
Lines: 21
Message-ID: <339E5AD5.ACC4E740@alumnos.inf-cr.uclm.es>
References: <01IJWRH12I828ZPPGT AT NICKEL DOT LAURENTIAN DOT CA>
NNTP-Posting-Host: est271.mag-cr.uclm.es
Mime-Version: 1.0
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

S2200253 AT nickel DOT laurentian DOT ca wrote:

> I'm trying to refine my understanding of the copy constructor and
> would
> like some clarification about it.
>
> Give a class called "Bozo".
>
> Bozo b; // creates a Bozo object
> Bozo anotherBozo(b);  // calls the copy constructor
> Bozo yetanotherBozo = b;  // does this also call the copy constructor?
>
> Also the Bozo copy constructor would be Bozo::Bozo(Bozo &)  Is this
> correct?
>
> Timothy Robb

  I think it's correct. But I'm no C++ guru (however want to).

    Roberto.

- Raw text -


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