Message ID | DB9PR01MB7466F182400680C1ACC93EA1A4482@DB9PR01MB7466.eurprd01.prod.exchangelabs.com |
---|---|
State | Not Applicable |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:bc8a:b0:106:860b:bbdd with SMTP id dn10csp88654dyb; Mon, 12 Feb 2024 10:16:56 -0800 (PST) X-Forwarded-Encrypted: i=4; AJvYcCVyP7pH05+GpezPrdoV2iI9fZRT68sTExu6Wxm5njE8DKWuBhfhdZ+thdXOSfXdm2xwE6b/QARXsTFnELSZc+yU1Skl7g== X-Google-Smtp-Source: AGHT+IG7CwYywT+i+4oRtzfkkNo0ETBcerE6JlefmbF1bhwjgfstW69OMQrpN1QzuRay9nL3LqL5 X-Received: by 2002:a05:6808:3a14:b0:3c0:3b9a:a99 with SMTP id gr20-20020a0568083a1400b003c03b9a0a99mr4098427oib.20.1707761816470; Mon, 12 Feb 2024 10:16:56 -0800 (PST) ARC-Seal: i=3; a=rsa-sha256; t=1707761816; cv=pass; d=google.com; s=arc-20160816; b=ia70ofSJT5avwIRClgwLSex3bNCM/t2QHEf36cYrCQhBlXTj6UjJyxRTzBh1Ojv+w/ VkAbmDCPu/IOhivDiSynZymHH3VbiIxC63w/VaNZ0mX9ZOUs1bh/wT9ftJiPyT1Tvkxp pGBl2c5CiwyDMbNmToO3PI5cHqOp10NvaFgft4XBnURT24RTvRiOxSgB6eqCNyVknTQo /bkDVsHkgakb/sgIAJfJI3pi6OV8D7bclEk45hwCrEICu+QS8jeixBeg2hJSxyto5edz FX0Ylb+tVrAqCFStYcHaRdZKaAyZnzcOPuPRhWCBOCSsKXDO7PdnkxTkpASFVAdf9uTt 4HEQ== ARC-Message-Signature: i=3; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:mime-version :content-transfer-encoding:msip_labels:content-language :accept-language:message-id:date:thread-index:thread-topic:subject :cc:to:from:dkim-signature:arc-filter:dmarc-filter:delivered-to; bh=93QxLBd4maymMI2HlJbTzEAHUixc0Hsb2WN4slMbeL4=; fh=YNgTCDKXd7M9Skvj7G9AsGbKYl5PZ2sYa18YDJ/nWXs=; b=YPs4/hPwZNVixCCDm2intDpNQ4qom+kw9aX2/hwSlo1x05egmGMZbMna9vV/3xEkiX gPbJzK1qU/1lXZiJuhwNpHrIVu0jEmi/6cIhgYMbwqKR7McvCgwIA7AfmwT4mHBldnY7 hWyGyRWwJP2rDwYr1Ah6GPxSNZjOI63ZY0qCThV86SZyIa0KjhIT9mcV2OhVF64K3Ds/ lUs2GuuHM0iY/4ncLSnBGsGOAo98WRarWWHmH6VhKt3VHs5YlNDGLewXTHf3WtZPEkPk 5IGoatOR0banBvvjaVPnH/S0J/EX9tOqhuq5LPr3pVyUsQHUWCczAS3jzfhhiv8w99+h OlGQ==; dara=google.com ARC-Authentication-Results: i=3; mx.google.com; dkim=pass header.i=@uws.ac.uk header.s=selector1 header.b=ZGz9Sr5l; arc=pass (i=2); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=uws.ac.uk X-Forwarded-Encrypted: i=3; AJvYcCVsJdqbznF142drJ5JCORlvFhJPNyeK7PWNAXwhh8LF9emobdITQxzBnrLupk/zZR4xjMa8nOlVcwDR0HHmqY0wgB5fEQ== Received: from server2.sourceware.org (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id h6-20020a05620a244600b00785bd252200si7083628qkn.745.2024.02.12.10.16.56 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Feb 2024 10:16:56 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; dkim=pass header.i=@uws.ac.uk header.s=selector1 header.b=ZGz9Sr5l; arc=pass (i=2); spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=uws.ac.uk Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 260F1385840A for <ouuuleilei@gmail.com>; Mon, 12 Feb 2024 18:16:56 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from EUR05-DB8-obe.outbound.protection.outlook.com (mail-db8eur05on2105.outbound.protection.outlook.com [40.107.20.105]) by sourceware.org (Postfix) with ESMTPS id 62E103858C98; Mon, 12 Feb 2024 18:15:52 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 62E103858C98 Authentication-Results: sourceware.org; dmarc=pass (p=reject dis=none) header.from=uws.ac.uk Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=uws.ac.uk ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 62E103858C98 Authentication-Results: server2.sourceware.org; arc=pass smtp.remote-ip=40.107.20.105 ARC-Seal: i=2; a=rsa-sha256; d=sourceware.org; s=key; t=1707761762; cv=pass; b=hBjE4ffEhsNkPWsELxhe8SEibQxJruRFZU0rUiaDDxswwcqNAkugRF+euouO77IrweFRrk698WLx6Y4fnG0kxazoReZSU21HLwCHcQiDFgPtJO/ZZK0kl8GrwZShxJmHrWAndoNIvNs0AK5inuptaxVi2TyvPM0z+JQz4KpH/r4= ARC-Message-Signature: i=2; a=rsa-sha256; d=sourceware.org; s=key; t=1707761762; c=relaxed/simple; bh=gGTubNAsTFP6YWFOKmLtytiDUv1NTxMTwkk9IzcJU2c=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=MeQe3xeTWLH8Ty5OEXQax90hNR23GuCq1lV7+Glse+nxEspzmHshpv99MTt1wbNOeZsp8HDXMUyljG3C03Ghpos4W1cZmsO7KO/bDYNGw5vZR8gSr3t6ztbvt2CPpTqUWLM5hvT2pap4maP3a6HAJKMug42Ozk2QsS/Z2US6Aqc= ARC-Authentication-Results: i=2; server2.sourceware.org ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=JMC+MZKlggAWdwBH/u5+T9udvOGJkqo07SOOgfSuDi30GPVxxCnDLeLNv8GjlyGVQgD24n1oHAfjwFrNxo2sfa4OQQBefG/iwiTzWWiWDtZvIWnXGD5QxEHTMU7MgL1n0gRq/MGjhjyr2RY5s0J/M8Hx/4dQFBVHxDDQv5Ldwa06w9ANqvUeFb1/ME/kN7McfNB1KwCnqv6RNS3A+UxncGCV3jOAScdZUp6dOEf8hOo5kYNDGBWs/ME9xWvj4ggpEK0CvlW72ImTf/s8xJ+s3fzfDVRZ5/I6AAc/h2G87uBIVq1f2B/nR90dATU5AGxL81HslAe4zi+d18UXVSCHdw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=93QxLBd4maymMI2HlJbTzEAHUixc0Hsb2WN4slMbeL4=; b=AE2hJn0Bd4qjbQF84CAufVB/HtTF0eS9mOkrTNWtGhs0qdBEbp7c0Pc8tZqzC8DVwviKEYrWwHWT+zvYQTiMWqyPTBcR+FPaJ32BKjE9PgYL3w7uI/gsVJKo1vgL3FNpv+ibwoqaoXJs/M6C/WoS7DdbtGrg4NkQBMbTpiWAW+ssw96reqEIEXUTyv5Gf6fet1ZIQkx/4rew0KrSRcY2F6LJDvlY2MMdqnl0l8gka9UGmvgEzm+UcIcQwiA3xxBsvBz/1iDd8L3rDCBVWyjB7VksuTPSWy3TMHNWJ71LcOoIQ5A0BgAMb45dK9gm52ecwWA/M6T1vLxeo6laVrMdhg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=uws.ac.uk; dmarc=pass action=none header.from=uws.ac.uk; dkim=pass header.d=uws.ac.uk; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=uws.ac.uk; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=93QxLBd4maymMI2HlJbTzEAHUixc0Hsb2WN4slMbeL4=; b=ZGz9Sr5l+hVpq7SvkD4qPourJnuBt3C/J706yrgmTi/3ccnZLybJzdg9sdah353nb3sr69U2Fx+wA0bzMvN3xW3VjebV/QIckYXFeltRAGgZbBD1dVqjpEs5vicR6KcgcVmLyKIJ4MzgHTCyW584ZxZeXAeIhyVnL34A/yw5I/EDt7Ryfx/Kp+WG7nE0yKW2jHwHpseLZkGqGjmbZASRg6OtfXdcP/YOE/wckiKoSd1qwFtYYCVJpLoI34Vnk5okyzh46iifDwh58IiDJ6EHI54yhP6IcpASOLM6NwJ2NEvPGqjM8PgwQ45lYKlZu2fM0Z5FdovXa3kovgOYrbZQBw== Received: from DB9PR01MB7466.eurprd01.prod.exchangelabs.com (2603:10a6:10:211::13) by PR3PR01MB6873.eurprd01.prod.exchangelabs.com (2603:10a6:102:70::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7270.38; Mon, 12 Feb 2024 18:15:50 +0000 Received: from DB9PR01MB7466.eurprd01.prod.exchangelabs.com ([fe80::d31d:d1e9:3e35:84b2]) by DB9PR01MB7466.eurprd01.prod.exchangelabs.com ([fe80::d31d:d1e9:3e35:84b2%3]) with mapi id 15.20.7270.036; Mon, 12 Feb 2024 18:15:49 +0000 From: Paul Keir <Paul.Keir@uws.ac.uk> To: "gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org> CC: "libstdc++@gcc.gnu.org" <libstdc++@gcc.gnu.org> Subject: [PATCH] libstdc++: Fix constexpr basic_string union member [PR113294] Thread-Topic: [PATCH] libstdc++: Fix constexpr basic_string union member [PR113294] Thread-Index: AQHaXd59L04VvKCYbECu1dj5V7mLKw== Date: Mon, 12 Feb 2024 18:15:49 +0000 Message-ID: <DB9PR01MB7466F182400680C1ACC93EA1A4482@DB9PR01MB7466.eurprd01.prod.exchangelabs.com> Accept-Language: en-GB, en-US Content-Language: en-GB X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_8a8eb34d-fba7-40f3-b856-61e3fd1d170f_Enabled=True; MSIP_Label_8a8eb34d-fba7-40f3-b856-61e3fd1d170f_SiteId=f89944b7-4a4e-4ea7-9156-3299f3411647; MSIP_Label_8a8eb34d-fba7-40f3-b856-61e3fd1d170f_SetDate=2024-02-12T18:15:49.739Z; MSIP_Label_8a8eb34d-fba7-40f3-b856-61e3fd1d170f_Name=Confidential; MSIP_Label_8a8eb34d-fba7-40f3-b856-61e3fd1d170f_ContentBits=0; MSIP_Label_8a8eb34d-fba7-40f3-b856-61e3fd1d170f_Method=Standard; authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=uws.ac.uk; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: DB9PR01MB7466:EE_|PR3PR01MB6873:EE_ x-ms-office365-filtering-correlation-id: 646f036a-e460-4959-dc3b-08dc2bf6a457 x-ms-exchange-atpmessageproperties: SA x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: daQPZ6f+yh4G8IkPOAqTJG67QUmy9QFR2mPNqZSD5evrr8wElxO0e5Zkgr/zVMretz/MCikkQER74VlLOpdCekgqH27E/0qwL3BwB5db9R+OdxhzTk+AqJXcuZYIvYG3VecdgKMuwXrxDAr9jqAazc7t0VYtECf0kM+YPfGJ2jBmrVgG6OHHhgBcsTzDoK+uloj+T1bTPTuwTlw1hubRCYtSJm68C26BlF6XMfo1OQR2p55EAN/96W8EGjc2dgveNjQJxcyL1AWSmymIoKHjpBHTiATRj2SSARw0mhUccRWY3c2fnrHkIEmgjr+YfFCCqr5YAKkRmNt5JzRSm7SAYY9DNM/zXF+AhvErbaw74pYW5W21jpROzVgLz9luWPm5NgMrVvymt3m27Ed46kPzq1jEKPcQSkA3MvLetPauGkrcVNYxzT+HZaVhVFkgVgXNH9scRXCOhDu+twq0nbCVVxsSMEAXm4gkdhE+LdMwt2grG+75LQLpkERI2gfo5SGBqJ5wFvCjH/pm1XphuX673ZH8S7qu0HmSBQ22eHILTV7RHaY8GxxQ3eXqCcXRLi0gcT7wmNuOjsMYg34VN12AvqC2tOpYrqg7IGsGw3EHhN4SRj05xXyqqAv9NLITnGQe x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DB9PR01MB7466.eurprd01.prod.exchangelabs.com; PTR:; CAT:NONE; SFS:(13230031)(39860400002)(396003)(376002)(136003)(366004)(346002)(64100799003)(451199024)(186009)(1800799012)(2906002)(55016003)(478600001)(41300700001)(38070700009)(4326008)(91956017)(5660300002)(450100002)(6916009)(9686003)(7696005)(71200400001)(8936002)(8676002)(76116006)(52536014)(66476007)(66556008)(66946007)(64756008)(66446008)(83380400001)(33656002)(86362001)(316002)(6506007)(786003)(38100700002)(122000001); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?iso-8859-1?q?q3GYUDjSK9aXtKx/hIJsUdl?= =?iso-8859-1?q?kBtIf6FKavMhgclbFdRHOtB/ie8k11Wfqrevk0YRfwJGDtXcQWmlLFrPWXZc?= =?iso-8859-1?q?8bqmGMDDIWLSVsLjgjJ10vZqr/Le8kz3oGmfP5ZLqV001ZG251nZkto/z7QN?= =?iso-8859-1?q?c0Fi9+C9H/nxpU4hnaK/OmPLwYBVBHrUXpQuiQ22bxpf+wcKnEQZIWBC0bgJ?= =?iso-8859-1?q?HA7/mjgFRdZlalPybet+Txu2aq7cv8juWLilTg+y3XhP+EacQs0HoDhpeMY+?= =?iso-8859-1?q?8MwOt7PgKiR/Y4b0GScsGZAtCAgX1JWgVRr+sWlyO0TjgorAzFxiHTvAU3Cv?= =?iso-8859-1?q?g8W5BKn3nIBCcx94x6LlxQuA5AT+y1MCWlS2OWmTfml+rvsaZJCFQgn0VS//?= =?iso-8859-1?q?suNAdjbBE7TudglV2QSXkWDeyZGNdeOyxxqJIds6BZJbQaltgUMr+KDTrkOK?= =?iso-8859-1?q?z6e41mAC/laDA2zQonmOrrYAi9mfjV+zcGdNSsjYMBbhlpL0vj0sLo3bzUJh?= =?iso-8859-1?q?smWqd9BDlGpKqsUdIEByFhVc/qyEmghTLoNuYpaVWgnP5Q4ADJ8yx0J2UiDk?= =?iso-8859-1?q?FXWh2Q8MnRtZVLLc3Wc3BOAGz5z4r3msp4PbFKlJ6LeQIdg1qKiATDDWnvbx?= =?iso-8859-1?q?EMpp0zSeikhTUnqdZJAXKiGEWEw9V4Q5pmp/AhOnrih+EOmSsBv14HuY8wNi?= =?iso-8859-1?q?rolLSSERP6sTrmq/l4i5t+sGxKSR5+LbsxvoKUYtozRjqL98uWHXYdu8X/Hf?= =?iso-8859-1?q?w0XounA8hyw1m5xhLZzGaHvFDAGQmVEONpAAMSqZvbYIO+b4HWxLe0vS4jVR?= =?iso-8859-1?q?2DoYIKMJMPywDzjKLWUQmvsQ61dMGLWPh4zJaZkYUlrWxSRPuRhTLtJeou41?= =?iso-8859-1?q?nFkpC+gA8LEzFfQMmL9dtloXcQQNKf2sXM3fGEvyzx2o3olk2Xw8oJsaRRST?= =?iso-8859-1?q?VwbztTX8YhShjOgLqNUOP1FVMFP/qOfo3WMrnJch4nxsKr1gbgTgD0Spn2DS?= =?iso-8859-1?q?2CXC3Cc90/jOUNPuy56BtXr5e2J0BtpcVNwc23tQf6ntt75CkR8B98lR6+fm?= =?iso-8859-1?q?dZUsu/mLKa7K3j/amzaH+HkxxrTRpXZtQaiq5fAPSEmCmVE82daVmqUWJQ52?= =?iso-8859-1?q?Jo8r7BmFjoq22F8+svsWlysxcudVEL+yy1prNdQRCLy/KXUhAx3ODzckKSG6?= =?iso-8859-1?q?aPgOMAIOuZdrAsZBjtIl5uZFNEQnHa9+nQhZ8PuJ59wMu49RPkgMKxRYcvIK?= =?iso-8859-1?q?4rne3C4hRw5vrJPJq6PJdEfJTvyuELOwSyYHty/OpO+rCGFyM5xp1dYpGiZB?= =?iso-8859-1?q?ZmZMJCrE49vGCcl4smHO67jTyRRIz12sZ9mu+CGwXw7Ph+CpKWSjmXH5v+qj?= =?iso-8859-1?q?kKGw1AkHdWUUJ8+8cZ/VSAkt1JkHxjDMbdYw1jQEG6zmr11/SFgY04cf66E9?= =?iso-8859-1?q?l703IsAwV6sz02vhQtvnZRqeUrAQrPcU8v4z+GSn4l1BgWuxVrAJzQBdw1mJ?= =?iso-8859-1?q?2leIohkF0zZbO4rrmlzKGGqb38nhRxGuJLtLA7n4TSi53VDCmXA2s85e/Mm3?= =?iso-8859-1?q?wq0aoaDyOEUTB9da6zPZplGu5Eo6GWH232THsjNynRFY5yIids4BvtchYoIy?= =?iso-8859-1?q?9P8DaMK2Mhq4nkgL7QH6T0sjmuniIY2QJgODnGQV/gsXvwkWar3DUdknI7FJ?= =?iso-8859-1?q?x0ma2aaR5Jfd8zKF/hyuR?= Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: uws.ac.uk X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DB9PR01MB7466.eurprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-Network-Message-Id: 646f036a-e460-4959-dc3b-08dc2bf6a457 X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Feb 2024 18:15:49.8649 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: f89944b7-4a4e-4ea7-9156-3299f3411647 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: xvRgohhFdw0SEFlEDwwgD53/gPyB2GMgEupIdp5ZudL+M0Nq/qam7G0q8DaoKx8UO79ahxXeM6dwTdK7GKSK2w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PR3PR01MB6873 X-Spam-Status: No, score=-10.3 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FORGED_SPF_HELO, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_PASS, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790718054341238758 X-GMAIL-MSGID: 1790718054341238758 |
Series |
libstdc++: Fix constexpr basic_string union member [PR113294]
|
|
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | fail | Git am fail log |
Commit Message
Paul Keir
Feb. 12, 2024, 6:15 p.m. UTC
A call to `basic_string::clear()` in the std::string move assignment operator leads to a constexpr error from an access of inactive union member `_M_local_buf` in the added test (`test_move()`). Changing `__str._M_local_buf` to `__str._M_use_local_data()` in `operator=(basic_string&& __str)` fixes this.
Running `make check RUNTESTFLAGS="conformance.exp=21_strings/basic_string/*"` on x86_64-pc-linux-gnu gave unchanged summary results (# of expected passes 570 # of expected failures 4 # of unsupported tests 4).
I don't have write access.
Signed-off-by: Paul Keir <paul.keir@uws.ac.uk>
--
Please consider the environment and think before you print.
The University of the West of Scotland is a registered Scottish charity. Charity number SC002520.
This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender.
Please note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of the University of the West of Scotland.
As a public body, the University of the West of Scotland may be required to make available emails as well as other written forms of information as a result of a request made under the Freedom of Information (Scotland) Act 2002.
Comments
On Mon, 12 Feb 2024, Paul Keir wrote: > A call to `basic_string::clear()` in the std::string move assignment operator leads to a constexpr error from an access of inactive union member `_M_local_buf` in the added test (`test_move()`). Changing `__str._M_local_buf` to `__str._M_use_local_data()` in `operator=(basic_string&& __str)` fixes this. > > Running `make check RUNTESTFLAGS="conformance.exp=21_strings/basic_string/*"` on x86_64-pc-linux-gnu gave unchanged summary results (# of expected passes 570 # of expected failures 4 # of unsupported tests 4). > > I don't have write access. > > Signed-off-by: Paul Keir <paul.keir@uws.ac.uk> LGTM! A ChangeLog entry is missing from the commit message, so here's one that we can use for this commit: PR libstdc++/113294 libstdc++-v3/ChangeLog: * include/bits/basic_string.h (basic_string::operator=): Use _M_use_local_data() instead of _M_local_buf on the moved-from string. * testsuite/21_strings/basic_string/modifiers/constexpr.cc (test_move): New test. > > diff --git a/libstdc++-v3/include/bits/basic_string.h b/libstdc++-v3/include/bits/basic_string.h > index 43efc99bea9..8a695a494ef 100644 > --- a/libstdc++-v3/include/bits/basic_string.h > +++ b/libstdc++-v3/include/bits/basic_string.h > @@ -909,7 +909,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11 > __str._M_capacity(__capacity); > } > else > - __str._M_data(__str._M_local_buf); > + __str._M_data(__str._M_use_local_data()); > } > else // Need to do a deep copy > assign(__str); > diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc b/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc > index 0e28a6d4487..ad7548f3236 100644 > --- a/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc > +++ b/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc > @@ -50,3 +50,16 @@ test_erasure() > } > > static_assert( test_erasure() ); > + > +constexpr bool > +test_move() > +{ > + std::string s1; > + std::string s2 = "1234567890123456"; // 16 chars: more than _S_local_capacity > + s1 = std::move(s2); > + VERIFY( s1 == "1234567890123456" ); > + > + return true; > +} > + > +static_assert( test_move() ); > -- > > > Please consider the environment and think before you print. > > The University of the West of Scotland is a registered Scottish charity. Charity number SC002520. > > This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. > > Please note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of the University of the West of Scotland. > > As a public body, the University of the West of Scotland may be required to make available emails as well as other written forms of information as a result of a request made under the Freedom of Information (Scotland) Act 2002. > >
On Mon, 12 Feb 2024 at 22:17, Patrick Palka <ppalka@redhat.com> wrote: > On Mon, 12 Feb 2024, Paul Keir wrote: > > > A call to `basic_string::clear()` in the std::string move assignment > operator leads to a constexpr error from an access of inactive union member > `_M_local_buf` in the added test (`test_move()`). Changing > `__str._M_local_buf` to `__str._M_use_local_data()` in > `operator=(basic_string&& __str)` fixes this. > > > > Running `make check > RUNTESTFLAGS="conformance.exp=21_strings/basic_string/*"` on > x86_64-pc-linux-gnu gave unchanged summary results (# of expected passes > 570 # of expected failures 4 # of unsupported tests 4). > > > > I don't have write access. > > > > Signed-off-by: Paul Keir <paul.keir@uws.ac.uk> > > LGTM! A ChangeLog entry is missing from the commit message, > so here's one that we can use for this commit: > > PR libstdc++/113294 > > libstdc++-v3/ChangeLog: > > * include/bits/basic_string.h (basic_string::operator=): Use > _M_use_local_data() instead of _M_local_buf on the moved-from > string. > * testsuite/21_strings/basic_string/modifiers/constexpr.cc > (test_move): New test. > The patch is OK for trunk and gcc-13 with that commit msg. Patrick, could you push it for Paul? Thank you both. > > > > diff --git a/libstdc++-v3/include/bits/basic_string.h > b/libstdc++-v3/include/bits/basic_string.h > > index 43efc99bea9..8a695a494ef 100644 > > --- a/libstdc++-v3/include/bits/basic_string.h > > +++ b/libstdc++-v3/include/bits/basic_string.h > > @@ -909,7 +909,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11 > > __str._M_capacity(__capacity); > > } > > else > > - __str._M_data(__str._M_local_buf); > > + __str._M_data(__str._M_use_local_data()); > > } > > else // Need to do a deep copy > > assign(__str); > > diff --git > a/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc > b/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc > > index 0e28a6d4487..ad7548f3236 100644 > > --- > a/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc > > +++ > b/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc > > @@ -50,3 +50,16 @@ test_erasure() > > } > > > > static_assert( test_erasure() ); > > + > > +constexpr bool > > +test_move() > > +{ > > + std::string s1; > > + std::string s2 = "1234567890123456"; // 16 chars: more than > _S_local_capacity > > + s1 = std::move(s2); > > + VERIFY( s1 == "1234567890123456" ); > > + > > + return true; > > +} > > + > > +static_assert( test_move() ); > > -- > > > > > > Please consider the environment and think before you print. > > > > The University of the West of Scotland is a registered Scottish charity. > Charity number SC002520. > > > > This e-mail and any attachment is for authorised use by the intended > recipient(s) only. It may contain proprietary material, confidential > information and/or be subject to legal privilege. It should not be copied, > disclosed to, retained or used by, any other party. If you are not an > intended recipient then please promptly delete this e-mail and any > attachment and all copies and inform the sender. > > > > Please note that any views or opinions presented in this email are > solely those of the author and do not necessarily represent those of the > University of the West of Scotland. > > > > As a public body, the University of the West of Scotland may be required > to make available emails as well as other written forms of information as a > result of a request made under the Freedom of Information (Scotland) Act > 2002. > > > > > >
diff --git a/libstdc++-v3/include/bits/basic_string.h b/libstdc++-v3/include/bits/basic_string.h index 43efc99bea9..8a695a494ef 100644 --- a/libstdc++-v3/include/bits/basic_string.h +++ b/libstdc++-v3/include/bits/basic_string.h @@ -909,7 +909,7 @@ _GLIBCXX_BEGIN_NAMESPACE_CXX11 __str._M_capacity(__capacity); } else - __str._M_data(__str._M_local_buf); + __str._M_data(__str._M_use_local_data()); } else // Need to do a deep copy assign(__str); diff --git a/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc b/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc index 0e28a6d4487..ad7548f3236 100644 --- a/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc +++ b/libstdc++-v3/testsuite/21_strings/basic_string/modifiers/constexpr.cc @@ -50,3 +50,16 @@ test_erasure() } static_assert( test_erasure() ); + +constexpr bool +test_move() +{ + std::string s1; + std::string s2 = "1234567890123456"; // 16 chars: more than _S_local_capacity + s1 = std::move(s2); + VERIFY( s1 == "1234567890123456" ); + + return true; +} + +static_assert( test_move() );