From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30325 invoked by alias); 1 Feb 2014 06:08:11 -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 30299 invoked by uid 48); 1 Feb 2014 06:08:06 -0000 From: "chengniansun at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/60018] New: Bogus conversion warning with optimization flag -O1 Date: Sat, 01 Feb 2014 06:08: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: chengniansun 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-02/txt/msg00009.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D60018 Bug ID: 60018 Summary: Bogus conversion warning with optimization flag -O1 Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: chengniansun at gmail dot com The -Wconversion should not be affected by the optimization flags.=20 For the following code, Gcc emits no warning with flag -O0, but one convers= ion warning with flag -O1.=20 $: cat s.c extern void fn1(unsigned); extern void fn3(void); void fn2(void); void fn2() { fn1((fn3(), 0) || 0); } $: gcc-trunk -c -Wconversion -std=3Dc11 -O0 s.c $: gcc-trunk -c -Wconversion -std=3Dc11 -O1 s.c s.c: In function =E2=80=98fn2=E2=80=99: s.c:5:7: warning: conversion to =E2=80=98unsigned int=E2=80=99 from =E2=80= =98int=E2=80=99 may change the sign of the result [-Wsign-conversion] fn1((fn3(), 0) || 0); ^ $: gcc-trunk -v Using built-in specs. COLLECT_GCC=3Dgcc-trunk COLLECT_LTO_WRAPPER=3D/home/chengniansun/tools/gcc-trunk-binaries/libexec/g= cc/x86_64-unknown-linux-gnu/4.9.0/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ../gcc-trunk/configure --enable-languages=3Dc,c++ --disable-multilib --prefix=3D/home/chengniansun/tools/gcc-trunk-binaries : (reconfigured) ../gcc-trunk/configure --enable-languages=3Dc,c++ --disable-multilib --prefix=3D/home/chengniansun/tools/gcc-trunk-binaries : (reconfigured) ../gcc-trunk/configure --enable-languages=3Dc,c++ --disable-multilib --prefix=3D/home/chengniansun/tools/gcc-trunk-binaries Thread model: posix gcc version 4.9.0 20140131 (experimental) (GCC) >>From gcc-bugs-return-442253-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Feb 01 06:20:58 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 3561 invoked by alias); 1 Feb 2014 06:20:57 -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 3536 invoked by uid 48); 1 Feb 2014 06:20:53 -0000 From: "ppluzhnikov at google dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/60019] New: [C++11] Bogus error: use of deleted function unique_ptr(const unique_ptr&) Date: Sat, 01 Feb 2014 06:20: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: ppluzhnikov at google 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-02/txt/msg00010.txt.bz2 Content-length: 1858 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D60019 Bug ID: 60019 Summary: [C++11] Bogus error: use of deleted function unique_ptr(const unique_ptr&) Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: ppluzhnikov at google dot com Google ref: b/12846752 Test: #include struct S {}; struct T : S {}; std::unique_ptr F(); const std::unique_ptr s =3D F(); Using recent trunk: g++ (GCC) 4.9.0 20140129 (experimental) t.cc:6:32: error: use of deleted function =E2=80=98std::unique_ptr<_Tp, _Dp>::unique_ptr(const std::unique_ptr<_Tp, _Dp>&) [with _Tp =3D S; _Dp =3D std::default_delete]=E2=80=99 const std::unique_ptr s =3D F(); ^ There is a copy constructor in unique_ptr.h that I believe is supposed to apply here: /** @brief Converting constructor from another type * * Requires that the pointer owned by @p __u is convertible to the * type of pointer owned by this object, @p __u does not own an array, * and @p __u has a compatible deleter type. */ template::pointer, point= er>, __not_>, typename conditional::value, is_same<_Ep, _Dp>, is_convertible<_Ep, _Dp>>::type>> unique_ptr(unique_ptr<_Up, _Ep>&& __u) noexcept : _M_t(__u.release(), std::forward<_Ep>(__u.get_deleter())) { } but for some reason it doesn't kick in. (Code builds fine under Clang.) >>From gcc-bugs-return-442254-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Feb 01 07:13:37 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 20260 invoked by alias); 1 Feb 2014 07:13:36 -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 20239 invoked by uid 48); 1 Feb 2014 07:13:32 -0000 From: "lanxingcan at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/60020] New: Considering backport regexp support to 4.8+ Date: Sat, 01 Feb 2014 07:13:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: lanxingcan 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: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-02/txt/msg00011.txt.bz2 Content-length: 611 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60020 Bug ID: 60020 Summary: Considering backport regexp support to 4.8+ Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: lanxingcan at gmail dot com As GCC 4.8.1+ is already C++11 languages feature complete, it's pity that regex, a major part of C++11 library feature does not supported in 4.8.x serials. Any plan on backport regexp support to GCC 4.8.x?