From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8985 invoked by alias); 29 Aug 2014 21:51:07 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 8965 invoked by uid 48); 29 Aug 2014 21:51:03 -0000 From: "richard-gccbugzilla at metafoo dot co.uk" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/62310] New: fails to consider default initializers (NSDMIs) when checking inheriting constructors Date: Fri, 29 Aug 2014 21:51:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: richard-gccbugzilla at metafoo dot co.uk X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-08/txt/msg02033.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D62310 Bug ID: 62310 Summary: fails to consider default initializers (NSDMIs) when checking inheriting constructors Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: richard-gccbugzilla at metafoo dot co.uk Consider: struct A { A(int); A() =3D delete; }; struct B { B(int); B() =3D delete; }; struct C : B { using B::B; A a =3D 0; } c(0); GCC rejects this valid code: :1:114: error: use of deleted function =E2=80=98C::C(int)=E2=80=99 :1:97: note: =E2=80=98C::C(int)=E2=80=99 is implicitly deleted becau= se the default definition would be ill-formed: :1:97: error: use of deleted function =E2=80=98A::A()=E2=80=99 :1:20: note: declared here However, if you remove the '=3D delete' from A, GCC does in fact call A::A(= int), so this seems to be limited to determining if the inheriting constructor sh= ould be deleted. >>From gcc-bugs-return-459537-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri Aug 29 21:54:31 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 11268 invoked by alias); 29 Aug 2014 21:54:31 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 11242 invoked by uid 48); 29 Aug 2014 21:54:28 -0000 From: "ettl.martin at gmx dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug other/62311] New: Found a potential copy and paste issue on in gcc/config/cr16.c Date: Fri, 29 Aug 2014 21:54:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: other X-Bugzilla-Version: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: ettl.martin at gmx dot de X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-08/txt/msg02034.txt.bz2 Content-length: 907 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62311 Bug ID: 62311 Summary: Found a potential copy and paste issue on in gcc/config/cr16.c Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: other Assignee: unassigned at gcc dot gnu.org Reporter: ettl.martin at gmx dot de Please take a look at following suspicious code, where the same statement appears twice in a logical or-operation: /*file gcc/config/cr16.c, line 2027*/ static bool cr16_frame_pointer_required (void) { return (cfun->calls_alloca || crtl->calls_eh_return || cfun->has_nonlocal_label || crtl->calls_eh_return); } As you can see, the statement crtl->calls_eh_return appears twice, which looks like a copy&paste issue. Best regards and many thanks Martin Ettl