From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id A71E138515E4; Wed, 22 Mar 2023 12:16:36 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A71E138515E4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1679487396; bh=Yty26mdQpJz5vh0YrOW1XjcfAtdVTFqkNG7y+eYhEok=; h=From:To:Subject:Date:From; b=G6lChNeoHQ/AA4ugfBGr6OtfIH8vfgafFmR/qO0ZDBHPqvzRFu7khjntqZR9+W8V4 yvFEbhlzCU4H0CDa8QyAmx5/ccPnW//x2ZW1oHz39UuXnnEycOTJbKhDjbvHbYFVrS TV8MRMTg9y9Ir2zh8MVXff/nK5JE8Up3SvPmnbQ8= From: "marxin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: =?UTF-8?B?W0J1ZyBjKysvMTA5MjQ3XSBOZXc6IFsxMyBSZWdyZXNzaW9uXSBl?= =?UTF-8?B?cnJvcjogY29udmVydGluZyB0byDigJhvcHRpb25hbDxXZWJDb3JlOjpTb3Vy?= =?UTF-8?B?Y2VCcnVzaDo6QnJ1c2g+4oCZIGZyb20gaW5pdGlhbGl6ZXIgbGlzdCB3b3Vs?= =?UTF-8?B?ZCB1c2UgZXhwbGljaXQgY29uc3RydWN0b3Ig4oCYb3B0aW9uYWw8X1RwPjo6?= =?UTF-8?B?b3B0aW9uYWwoX1VwKSBbd2l0aCBfVXAgPSBpbnQ7IF9UcCA9IFdlYkNvcmU6?= =?UTF-8?B?OlNvdXJjZUJydXNoOjpCcnVzaF3igJkgc2luY2UgcjEzLTY3NjUtZ2EyMjY1?= =?UTF-8?B?OTBmZWZiMzVlZDY=?= Date: Wed, 22 Mar 2023 12:16:36 +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: 13.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 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D109247 Bug ID: 109247 Summary: [13 Regression] error: converting to =E2=80=98optional=E2=80=99= from initializer list would use explicit constructor =E2=80=98optional<_Tp>::optional(_Up) [with _Up =3D int= ; _Tp =3D WebCore::SourceBrush::Brush]=E2=80=99 since r13-6765-ga226590fefb35ed6 Product: gcc Version: 13.0 Status: UNCONFIRMED Keywords: rejects-valid Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: marxin at gcc dot gnu.org CC: mpolacek at gcc dot gnu.org Target Milestone: --- The following is reduced from webkit2gtk3:gtk3 package: $ cat webcore13.ii template struct optional { template explicit optional(_Up); template void operator=3D(_Up); }; namespace WebCore { int setPattern_pattern; struct SourceBrush { struct Brush { int brush; }; void setPattern() { m_brush =3D {setPattern_pattern}; } optional m_brush; }; } // namespace WebCore $ clang++ webcore13.ii -c && g++-12 webcore13.ii -c $ g++ webcore13.ii -c webcore13.ii: In member function =E2=80=98void WebCore::SourceBrush::setPat= tern()=E2=80=99: webcore13.ii:11:52: error: converting to =E2=80=98optional=E2=80=99 from initializer li= st would use explicit constructor =E2=80=98optional<_Tp>::optional(_Up) [with _Up =3D in= t; _Tp =3D WebCore::SourceBrush::Brush]=E2=80=99 11 | void setPattern() { m_brush =3D {setPattern_pattern}; } | ^=