From patchwork Sun Nov 27 22:04:58 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Botcazou X-Patchwork-Id: 84344 Delivered-To: patch@linaro.org Received: by 10.140.20.101 with SMTP id 92csp897436qgi; Sun, 27 Nov 2016 14:05:31 -0800 (PST) X-Received: by 10.98.68.140 with SMTP id m12mr18672142pfi.19.1480284331579; Sun, 27 Nov 2016 14:05:31 -0800 (PST) Return-Path: Received: from sourceware.org (server1.sourceware.org. [209.132.180.131]) by mx.google.com with ESMTPS id 88si24145273pla.48.2016.11.27.14.05.31 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 27 Nov 2016 14:05:31 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-return-442742-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) client-ip=209.132.180.131; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org; spf=pass (google.com: domain of gcc-patches-return-442742-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom=gcc-patches-return-442742-patch=linaro.org@gcc.gnu.org DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:mime-version:content-type :content-transfer-encoding; q=dns; s=default; b=NgVc1p/p0SlnNSPU KLqLJrFeNcA8CupaxTsOMRPLjyn2LwHY3INkPD04FWdNR+1Ga9EV/wC6x4SQy4Xv EQ0Lkodn9hh5xhilIjZD5nFD035j6TDyqKhZg7S/xLnJDp9MnpJ/O287SS2GIl+T E+7M/gU/JG9RKjlB/o3lvOL+niA= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:mime-version:content-type :content-transfer-encoding; s=default; bh=4h1AtP1H9SYpr4S/PPIkxs K0pC8=; b=NMOv5bMd2JaisGGh8Yu6qEMbagESOZCAu21HprhL5ZI5ZN5AppnKyv YJGXuc0Nm0Jw2eTfpV5n1Yln2KpZHJHm5OO+k75rbfOs4ParvWEsmNhn2B3mrplB 0OjkyjetSpeuWrabYYyBxarCmMhQXJcoP7UM+nAnKdVuw6c6YU0yU= Received: (qmail 38600 invoked by alias); 27 Nov 2016 22:05:12 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 38582 invoked by uid 89); 27 Nov 2016 22:05:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: smtp.eu.adacore.com Received: from mel.act-europe.fr (HELO smtp.eu.adacore.com) (194.98.77.210) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 27 Nov 2016 22:05:01 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-smtp.eu.adacore.com (Postfix) with ESMTP id A9CEF812F9 for ; Sun, 27 Nov 2016 23:04:59 +0100 (CET) Received: from smtp.eu.adacore.com ([127.0.0.1]) by localhost (smtp.eu.adacore.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id J0ZVxxIas7l0 for ; Sun, 27 Nov 2016 23:04:59 +0100 (CET) Received: from polaris.localnet (bon31-6-88-161-99-133.fbx.proxad.net [88.161.99.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.eu.adacore.com (Postfix) with ESMTPSA id 8809B812F2 for ; Sun, 27 Nov 2016 23:04:59 +0100 (CET) From: Eric Botcazou To: gcc-patches@gcc.gnu.org Subject: [Ada] Fix PR ada/78524 Date: Sun, 27 Nov 2016 23:04:58 +0100 Message-ID: <4461235.SPGCjJISnp@polaris> User-Agent: KMail/4.14.10 (Linux/3.16.7-48-desktop; KDE/4.14.9; x86_64; ; ) MIME-Version: 1.0 This is the failure of ACATS c41104a introduced by the recent match.pd change. Fixed thusly, tested on x86_64-suse-linux, applied on the mainline. 2016-11-27 Eric Botcazou PR ada/78524 * gcc-interface/utils.c (max_size) : Add missing conversion to original type in the PLACEHOLDER_EXPR case. -- Eric Botcazou Index: gcc-interface/utils.c =================================================================== --- gcc-interface/utils.c (revision 242863) +++ gcc-interface/utils.c (working copy) @@ -3548,7 +3548,9 @@ max_size (tree exp, bool max_p) { tree val_type = TREE_TYPE (TREE_OPERAND (exp, 1)); tree val = (max_p ? TYPE_MAX_VALUE (type) : TYPE_MIN_VALUE (type)); - return max_size (convert (get_base_type (val_type), val), true); + return + convert (type, + max_size (convert (get_base_type (val_type), val), true)); } return exp;