| delorie.com/archives/browse.cgi | search |
| Newsgroups: | comp.os.msdos.djgpp,comp.lang.c++ |
| From: | ark AT research DOT att DOT com (Andrew Koenig) |
| Subject: | Re: Problems using CYGWIN |
| X-Nntp-Posting-Host: | raptor.research.att.com |
| Message-ID: | <FBvqL7.6Gr@research.att.com> |
| Sender: | nntp AT research DOT att DOT com |
| Organization: | AT&T Research, Florham Park, NJ |
| References: | <373FBB9C DOT FE26B278 AT netvigator DOT com> |
| Date: | Mon, 17 May 1999 13:53:31 GMT |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
| Reply-To: | djgpp AT delorie DOT com |
In article <373FBB9C DOT FE26B278 AT netvigator DOT com>,
NG Chi Fai <cfng1 AT netvigator DOT com> wrote:
> Please help solve the problem. It seems the Segmentation fault happens
> after the cout << line. However, there is something wrong before the
> cout << line because the output data are corrupted.
Your class is missing a copy constructor, which it uses here:
> a<T> duplicate(void)
> {
> a<T> temp;
> temp=*this;
> return temp; // uses the copy constructor
> };
--
Andrew Koenig
ark AT research DOT att DOT com
http://www.research.att.com/info/ark
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |