From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 80BE9385E00F; Wed, 30 Jun 2021 14:27:17 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 80BE9385E00F From: "marxin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: =?UTF-8?B?W0J1ZyBsaWJzdGRjKysvMTAxMjcxXSBOZXc6IFsxMiBSZWdyZXNz?= =?UTF-8?B?aW9uXSBlcnJvcjog4oCYc3RhdGljIGNvbnN0ZXhwciBkZWNsdHlwZSAuLi4g?= =?UTF-8?B?dXNlZCBiZWZvcmUgaXRzIGRlZmluaXRpb24=?= Date: Wed, 30 Jun 2021 14:27:17 +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: 12.0 X-Bugzilla-Keywords: rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: marxin at gcc dot gnu.org 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 keywords bug_severity priority component assigned_to reporter cc 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-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 30 Jun 2021 14:27:17 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D101271 Bug ID: 101271 Summary: [12 Regression] error: =E2=80=98static constexpr declty= pe ... used before its definition Product: gcc Version: 12.0 Status: UNCONFIRMED Keywords: rejects-valid Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: marxin at gcc dot gnu.org CC: redi at gcc dot gnu.org Target Milestone: --- Created attachment 51090 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D51090&action=3Dedit test-case It's a recent regression. The test-case comes from blender package: $ g++ blender.ii -c In file included from /usr/include/openvdb/tree/LeafBuffer.h:10, from /usr/include/openvdb/tree/LeafNode.h:11, from /usr/include/openvdb/tree/Tree.h:18, from /usr/include/openvdb/Grid.h:12, from /usr/include/openvdb/openvdb.h:12, from /home/abuild/rpmbuild/BUILD/blender-2.92.0/extern/mantaflow/preprocessed/fi= leio/iovdb.cpp:31: /usr/include/tbb/atomic.h:21:141: note: =E2=80=98#pragma message: TBB Warni= ng: tbb/atomic.h is deprecated. For details, please see Deprecated Features appendix in the TBB reference manual.=E2=80=99 In file included from /usr/include/openvdb/tools/PointPartitioner.h:26, from /usr/include/openvdb/tools/PointIndexGrid.h:19, from /usr/include/openvdb/points/PointConversion.h:15, from /home/abuild/rpmbuild/BUILD/blender-2.92.0/extern/mantaflow/preprocessed/fi= leio/iovdb.cpp:32: /usr/include/tbb/task_scheduler_init.h:21:154: note: =E2=80=98#pragma messa= ge: TBB Warning: tbb/task_scheduler_init.h is deprecated. For details, please see Deprecated Features appendix in the TBB reference manual.=E2=80=99 In file included from /usr/include/c++/12/memory:76, from /usr/include/tbb/tbb_stddef.h:452, from /usr/include/tbb/blocked_range3d.h:20, from /home/abuild/rpmbuild/BUILD/blender-2.92.0/extern/mantaflow/preprocessed/ke= rnel.h:23, from /home/abuild/rpmbuild/BUILD/blender-2.92.0/extern/mantaflow/preprocessed/gr= id.h:26, from /home/abuild/rpmbuild/BUILD/blender-2.92.0/extern/mantaflow/preprocessed/fi= leio/iovdb.cpp:25: /usr/include/c++/12/bits/unique_ptr.h: In instantiation of =E2=80=98typename std::add_lvalue_reference<_Tp>::type std::unique_ptr<_Tp [], _Dp>::operator[](std::size_t) const [with _Tp =3D unsigned int; _Dp =3D std::default_delete; typename std::add_lvalue_reference<_Tp>::type =3D unsigned int&; std::size_t =3D long unsigned int]=E2=80=99: /usr/include/openvdb/tools/PointIndexGrid.h:447:20: required from here /usr/include/c++/12/bits/unique_ptr.h:672:55: error: =E2=80=98static conste= xpr decltype ((sizeof (_Elt) !=3D 0)) std::unique_ptr<_Tp [], _Dp>::_S_nothrow_deref(std::size_t) [with _Ptr =3D unsigned int*; _Elt =3D = unsigned int; _Tp =3D unsigned int; _Dp =3D std::default_delete; de= cltype ((sizeof (_Elt) !=3D 0)) =3D bool; std::size_t =3D long unsigned int]=E2=80= =99 used before its definition=