From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18115 invoked by alias); 3 Jul 2014 02:23:23 -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 16564 invoked by uid 48); 3 Jul 2014 02:23:04 -0000 From: "bbi5291 at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/61683] New: decltype-specifier not accepted as mem-initializer-id Date: Thu, 03 Jul 2014 02:23: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: 4.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: bbi5291 at gmail dot com 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-07/txt/msg00134.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D61683 Bug ID: 61683 Summary: decltype-specifier not accepted as mem-initializer-id Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: bbi5291 at gmail dot com $ cat main.cpp struct A {}; A a; struct B : A { B(): decltype(a)() {} }; int main() {} $ g++ -v Using built-in specs. COLLECT_GCC=3Dg++ COLLECT_LTO_WRAPPER=3D/usr/local/libexec/gcc/x86_64-unknown-linux-gnu/4.9.0= /lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ./configure --program-suffix=3D-4.9.0 Thread model: posix gcc version 4.9.0 (GCC)=20 $ g++-4.9.0 -std=3Dc++11 main.cpp main.cpp: In constructor =E2=80=98B::B()=E2=80=99: main.cpp:4:10: error: expected identifier before =E2=80=98decltype=E2=80=99 B(): decltype(a)() {} ^ main.cpp:4:10: error: expected =E2=80=98{=E2=80=99 before =E2=80=98decltype= =E2=80=99 -- This code should compile because the standard says that any class-or-declty= pe that denotes a base class can be used in a mem-initializer-list. clang accepts: http://coliru.stacked-crooked.com/a/b50333efbcab9d26 >>From gcc-bugs-return-455544-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Thu Jul 03 02:32:00 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 25324 invoked by alias); 3 Jul 2014 02:30: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 Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 25008 invoked by uid 48); 3 Jul 2014 02:30:08 -0000 From: "jason at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/61382] parameter pack expansion unexpected order Date: Thu, 03 Jul 2014 02:30: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.9.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jason at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: jason at gcc dot gnu.org X-Bugzilla-Target-Milestone: 4.10.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: 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: 2014-07/txt/msg00135.txt.bz2 Content-length: 495 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61382 --- Comment #10 from Jason Merrill --- (In reply to Brooks Moses from comment #9) > FWIW, the new initlist86.C test that this adds is failing on the > google/gcc-4_9 branch on powerpc64le and aarch64, though it passes on > x86_64. I haven't yet checked on the upstream 4.9 branch, but I figured a > heads-up might be useful. Thanks. Does removing "PUSH_ARGS_REVERSED &&" from the cp_gimplify_expr change fix it?