From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 497 invoked by alias); 21 Sep 2015 14:37:35 -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 464 invoked by uid 48); 21 Sep 2015 14:37:31 -0000 From: "arvo at me dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/67670] New: [c++11] Misleading / outdated error message "invalid pure specifier" Date: Mon, 21 Sep 2015 14:37: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: 5.1.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: trivial X-Bugzilla-Who: arvo at me dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: 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 target_milestone attachments.created 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: 2015-09/txt/msg01721.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D67670 Bug ID: 67670 Summary: [c++11] Misleading / outdated error message "invalid pure specifier" Product: gcc Version: 5.1.1 Status: UNCONFIRMED Severity: trivial Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: arvo at me dot com Target Milestone: --- Created attachment 36367 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D36367&action=3Dedit Minimal test program (no headers/macros) g++ (Ubuntu 5.1.1-4ubuntu12) 5.1.1 20150504 x86_64 GNU/Linux Ubuntu 15.04 Command line: g++ -c -std=3Dc++11 wrong-default.cxx command output: wrong-default.cxx:6:17: error: invalid pure specifier (only =E2=80=98=3D 0= =E2=80=99 is allowed) before =E2=80=98;=E2=80=99 token X::X() =3D defaut; ^ wrong-default.cxx:6:17: error: function =E2=80=98X::X()=E2=80=99 is initial= ized like a variable I am not suggesting a "Did you mean 'default'?" message, but, in C++11, obviously the statement "only '=3D 0' is allowed" is wrong. That is true fo= r the *pure-specifier*, an optional part of a *member-declarator*, but '=3D defau= lt' or '=3D delete' is valid as a *function-body* in a *function-definition*. Curi= ously, a *member-declarator* may only occur inside a *class-specifier*, which means that '=3D 0' is not even allowed here, even for a virtual method of X (thou= gh I am only looking at draft N3690). >>From gcc-bugs-return-497744-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Sep 21 14:41:46 2015 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 27591 invoked by alias); 21 Sep 2015 14:41:45 -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 27393 invoked by uid 48); 21 Sep 2015 14:41:42 -0000 From: "manu at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/67668] erroneous type argument for unary operator one's complement Date: Mon, 21 Sep 2015 14:41:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 4.8.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: manu at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: INVALID 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_status cc resolution Message-ID: In-Reply-To: References: 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: 2015-09/txt/msg01722.txt.bz2 Content-length: 977 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D67668 Manuel L=C3=B3pez-Ib=C3=A1=C3=B1ez changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED CC| |manu at gcc dot gnu.org Resolution|--- |INVALID --- Comment #3 from Manuel L=C3=B3pez-Ib=C3=A1=C3=B1ez --- Marc is right: The operator =E2=80=98~=E2=80=99 performs complex conjugation when used on = a value with a complex type. This is a GNU extension; for values of floating type, you sho= uld use the ISO C99 functions conjf, conj and conjl, declared in and also provided as built-in functions by GCC.=20 test.c:3:3: warning: ISO C does not support =E2=80=98~=E2=80=99 for complex= conjugation [-Wpedantic] ~( 1. + 0.i ) ;=20 ^ >>From gcc-bugs-return-497745-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Sep 21 14:44:41 2015 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 47511 invoked by alias); 21 Sep 2015 14:44:40 -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 47475 invoked by uid 48); 21 Sep 2015 14:44:35 -0000 From: "redi at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/67670] [c++11] Misleading / outdated error message "invalid pure specifier" Date: Mon, 21 Sep 2015 14:44:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 5.1.1 X-Bugzilla-Keywords: diagnostic X-Bugzilla-Severity: normal X-Bugzilla-Who: redi at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: 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: keywords bug_status cf_reconfirmed_on everconfirmed bug_severity Message-ID: In-Reply-To: References: 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: 2015-09/txt/msg01723.txt.bz2 Content-length: 645 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67670 Jonathan Wakely changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |diagnostic Status|UNCONFIRMED |NEW Last reconfirmed| |2015-09-21 Ever confirmed|0 |1 Severity|trivial |normal --- Comment #1 from Jonathan Wakely --- I thought we already had a PR for this, but I can't find it.