Message ID | 20230116144848.3171399-1-poulhies@adacore.com |
---|---|
State | Unresolved |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp1231768wrn; Mon, 16 Jan 2023 06:52:34 -0800 (PST) X-Google-Smtp-Source: AMrXdXtasZhT0ac/dx983BuMr6y/+OXlVEKcpKaZS9Y2+TeNM2hdwm8Odshv81PmFHYvbEx/nwdq X-Received: by 2002:a05:6402:48c:b0:483:d49f:e26c with SMTP id k12-20020a056402048c00b00483d49fe26cmr70525274edv.15.1673880754516; Mon, 16 Jan 2023 06:52:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673880754; cv=none; d=google.com; s=arc-20160816; b=htg7/rA9jtMx8voCUclFXMcv+AUIuwmn7Ae9y2jKnoonzyScctTg1t+zaLp2pz5nNu n2iQxNsS4GaEwxOlZz77ZicRvK9RjUAwbfbZajBZMpE3iCR3kIwiS8ke6C29UiehdN0J sWOK2Qdrbo379m05vDEuBPmiBdBBWHVDQm6VnSoStDj5Z8NEvxx5Y0+ugjI3va8ABTbK oy9VeigVlogj/jOH0ujiYA8ZznVNUPoHav2tEs0/iAAXDILIb3JeY6UHaaP9iqM+n2oA 4TvJpL7a9nmChBa9yx106nM/3F7wC8GHuykw92VBhNItEhdle20coAv/yKeBYPXf1xZQ Gu1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:from:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence :content-transfer-encoding:mime-version:message-id:date:subject:cc :to:dmarc-filter:delivered-to:dkim-signature:dkim-filter; bh=k30NTg4eJS5XRoTD+ESR/d/aOFAebXG3rz5k9TWM2Dw=; b=pY0kxh8Dt9La79UKx7cpBOxAD316mMqyWLKN1nvahkz2kaI9HjFR+JT4Ef608I5cy7 8hapA2fV4uEsu+F6X9qD+Vi6WXSS5k4Ez3wYhKFpU1CfrFeYzBE6mZi03Syd4SR3xrhs L+98E0WKYxWvoQjnm2xt36bW0qowleaJmXP+bcifguyobZrmwnwTmbOxoYqRnAagE7ll hE5t0aHEs1n43I0q6wfV2st+Ye83LL4E1XTGWL0C10RQGtdtgFOw+ZxMAx0Fn4MmILP9 9xxLliJnFUu84i30aSG2HxO4Acfqwh9pe07Ym/T+XN738wITzb8whAARNHaH90DOBHoj 0LUg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=sPixcqOj; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from sourceware.org (ip-8-43-85-97.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id m5-20020a056402430500b0046a8fe6d173si38067995edc.456.2023.01.16.06.52.34 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Jan 2023 06:52:34 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=sPixcqOj; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id CD1A13881D3B for <ouuuleilei@gmail.com>; Mon, 16 Jan 2023 14:50:36 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org CD1A13881D3B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1673880636; bh=k30NTg4eJS5XRoTD+ESR/d/aOFAebXG3rz5k9TWM2Dw=; h=To:Cc:Subject:Date:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From:Reply-To:From; b=sPixcqOjDnfpAMhuVhrcGJW8hE3Kc2g/vBPa0v5VVUf6NDNqnaXFt1R02l4pQ8CMO alY1vY0vRtTWdJEofeS40cYYHcyQRoIgSvX4YHK96sDBfMNLamxp+aWnXS+Lakdyyh CUM1pe8XsCQ2H1V98m0Y4n9go1k3rywCmaR5T8Nw= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-wr1-x429.google.com (mail-wr1-x429.google.com [IPv6:2a00:1450:4864:20::429]) by sourceware.org (Postfix) with ESMTPS id 4B9473858000 for <gcc-patches@gcc.gnu.org>; Mon, 16 Jan 2023 14:48:52 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 4B9473858000 Received: by mail-wr1-x429.google.com with SMTP id q10so8388991wrs.2 for <gcc-patches@gcc.gnu.org>; Mon, 16 Jan 2023 06:48:52 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=k30NTg4eJS5XRoTD+ESR/d/aOFAebXG3rz5k9TWM2Dw=; b=0+5EjU8C8kVNucEBrHkIepzhoHkGnP1kZrmb+P9uuvK7VC7CphBPeAO0r5FGIktbg6 2JlhlzInA0U1WvAiU0oS1faSJmAdL/jGZA5FeDoImVgZ2QJrUSXDZSZXNFRWO8tgiTrw 6nj0w1xk+rvcm6mLgof9p3C7CT6EuR+EBqnICT6KIeF/tQVmewJ1+PeOXyCLMmyLVgXP 9/zgqvJWZfxkjFwprtUuvqOYsIQjAAp96g6aocMiFPc0VTC6nhUN53lmmoqx2stEuJs2 k9kS0LMv9BP7QAD/RIKgFLVe7/LckSUy3NQC6+tzDfD+kvqMXfCi6YlUxKoHjJI0B6HF YX1A== X-Gm-Message-State: AFqh2kpBZgmEJ8WDAApr1yf7PJh7mAkL97d8tIngU53FwK50WwnWCGRc KoXM8D1eM1/ZaBfMLNogCvwsiQvYZcSt2/TH X-Received: by 2002:adf:e442:0:b0:2bd:eb6a:cd43 with SMTP id t2-20020adfe442000000b002bdeb6acd43mr7962273wrm.15.1673880531116; Mon, 16 Jan 2023 06:48:51 -0800 (PST) Received: from poulhies-Precision-5550.telnowedge.local (lmontsouris-659-1-24-67.w81-250.abo.wanadoo.fr. [81.250.175.67]) by smtp.gmail.com with ESMTPSA id v14-20020adff68e000000b002365730eae8sm26577932wrp.55.2023.01.16.06.48.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Jan 2023 06:48:50 -0800 (PST) To: gcc-patches@gcc.gnu.org Cc: Eric Botcazou <ebotcazou@adacore.com> Subject: [COMMITTED] ada: Put back conversion to interface in more cases Date: Mon, 16 Jan 2023 15:48:48 +0100 Message-Id: <20230116144848.3171399-1-poulhies@adacore.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-13.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP 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.29 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> From: =?utf-8?q?Marc_Poulhi=C3=A8s_via_Gcc-patches?= <gcc-patches@gcc.gnu.org> Reply-To: =?utf-8?q?Marc_Poulhi=C3=A8s?= <poulhies@adacore.com> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1755191185804827865?= X-GMAIL-MSGID: =?utf-8?q?1755191185804827865?= |
Series |
[COMMITTED] ada: Put back conversion to interface in more cases
|
|
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | warning | Git am fail log |
Commit Message
Marc Poulhiès
Jan. 16, 2023, 2:48 p.m. UTC
From: Eric Botcazou <ebotcazou@adacore.com>
This needs to be done for all expressions with class-wide type.
gcc/ada/
* exp_ch3.adb (Make_Allocator_For_Return): Put back an interface
conversion for expressions with non-interface class-wide type.
Tested on x86_64-pc-linux-gnu, committed on master.
---
gcc/ada/exp_ch3.adb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/ada/exp_ch3.adb b/gcc/ada/exp_ch3.adb index c866a9c40f5..84594ed106b 100644 --- a/gcc/ada/exp_ch3.adb +++ b/gcc/ada/exp_ch3.adb @@ -7185,7 +7185,7 @@ package body Exp_Ch3 is -- remove earlier in the processing. if Is_Interface (Typ) - and then Is_Interface (Etype (Alloc_Expr)) + and then Is_Class_Wide_Type (Etype (Alloc_Expr)) and then Typ /= Etype (Alloc_Expr) then Alloc_Expr := Convert_To (Typ, Alloc_Expr);