From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16812 invoked by alias); 6 Mar 2013 18:07:58 -0000 Received: (qmail 16747 invoked by uid 22791); 6 Mar 2013 18:07:56 -0000 X-SWARE-Spam-Status: No, hits=-2.2 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from mel.act-europe.fr (HELO mel.act-europe.fr) (194.98.77.210) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 06 Mar 2013 18:07:23 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-smtp.eu.adacore.com (Postfix) with ESMTP id CCA61290086 for ; Wed, 6 Mar 2013 19:07:22 +0100 (CET) Received: from mel.act-europe.fr ([127.0.0.1]) by localhost (smtp.eu.adacore.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 1lSvAk4uPSyC for ; Wed, 6 Mar 2013 19:07:22 +0100 (CET) Received: from polaris.localnet (bon31-6-88-161-99-133.fbx.proxad.net [88.161.99.133]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mel.act-europe.fr (Postfix) with ESMTP id ACCFB290008 for ; Wed, 6 Mar 2013 19:07:22 +0100 (CET) From: Eric Botcazou To: gcc-patches@gcc.gnu.org Subject: [Ada] Minor tweak to Attribute_to_gnu Date: Wed, 06 Mar 2013 18:07:00 -0000 Message-ID: <1561581.qtl2GTx47f@polaris> User-Agent: KMail/4.7.2 (Linux/3.1.10-1.16-desktop; KDE/4.7.2; x86_64; ; ) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="nextPart1934350.Qx5ccO9d40" Content-Transfer-Encoding: 7Bit Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2013-03/txt/msg00267.txt.bz2 --nextPart1934350.Qx5ccO9d40 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Content-length: 381 Just to stop the compiler properly instead of erroring out on some ill-formed inputs going through the FE down to here. No functional changes. Tested on x86_64-suse-linux, applied on the mainline. 2013-03-06 Eric Botcazou * gcc-interface/trans.c (Attribute_to_gnu): Abort instead of erroring out for an unimplemented attribute. -- Eric Botcazou --nextPart1934350.Qx5ccO9d40 Content-Disposition: attachment; filename="p.diff" Content-Transfer-Encoding: 7Bit Content-Type: text/x-patch; charset="UTF-8"; name="p.diff" Content-length: 819 Index: gcc-interface/trans.c =================================================================== --- gcc-interface/trans.c (revision 196504) +++ gcc-interface/trans.c (working copy) @@ -2066,13 +2066,8 @@ Attribute_to_gnu (Node_Id gnat_node, tre break; default: - /* Say we have an unimplemented attribute. Then set the value to be - returned to be a zero and hope that's something we can convert to - the type of this attribute. */ - post_error ("unimplemented attribute", gnat_node); - gnu_result_type = get_unpadded_type (Etype (gnat_node)); - gnu_result = integer_zero_node; - break; + /* This abort means that we have an unimplemented attribute. */ + gcc_unreachable (); } /* If this is an attribute where the prefix was unused, force a use of it if --nextPart1934350.Qx5ccO9d40--