public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: shulga@ftc.ru
To: gcc-gnats@gcc.gnu.org
Subject: c++/8053: don't called copy constructor
Date: Wed, 25 Sep 2002 21:46:00 -0000	[thread overview]
Message-ID: <20020926044420.14645.qmail@sources.redhat.com> (raw)


>Number:         8053
>Category:       c++
>Synopsis:       don't called copy constructor
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Sep 25 21:46:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     shulga@ftc.ru
>Release:        gcc 3.0.2
>Organization:
>Environment:
$ uname -a
SunOS host 5.6 Generic_105181-29 sun4u sparc SUNW,Ultra-4

$ gcc -v
Reading specs from /usr/local/gcc302/lib/gcc-lib/sparc-sun-solaris2.6/3.0.2/specs
Configured with: ./configure --prefix=/usr/local/gcc302 --enable-languages=c,c++ --enable-threads=posix
Thread model: posix
gcc version 3.0.2
>Description:
There is no copy constructor call after calling c1(int) constructor in the statement c=c1(100).
>How-To-Repeat:
#include <stdio.h>

class c1 {
public:
  c1(const c1& c) {
    fprintf(stderr,"call c1(const c1&)\n");
  }
  c1(int aa) {
    fprintf(stderr,"call c1(int)\n");
  }
};

int main()
{
  c1 c=c1(10);
}
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


             reply	other threads:[~2002-09-26  4:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-09-25 21:46 shulga [this message]
2002-09-30  9:56 nathan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20020926044420.14645.qmail@sources.redhat.com \
    --to=shulga@ftc.ru \
    --cc=gcc-gnats@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).