* [Ada] Minor tweak to Attribute_to_gnu
@ 2013-03-06 18:07 Eric Botcazou
0 siblings, 0 replies; only message in thread
From: Eric Botcazou @ 2013-03-06 18:07 UTC (permalink / raw)
To: gcc-patches
[-- Attachment #1: Type: text/plain, Size: 381 bytes --]
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 <ebotcazou@adacore.com>
* gcc-interface/trans.c (Attribute_to_gnu): Abort instead of erroring
out for an unimplemented attribute.
--
Eric Botcazou
[-- Attachment #2: p.diff --]
[-- Type: text/x-patch, Size: 819 bytes --]
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
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2013-03-06 18:07 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-06 18:07 [Ada] Minor tweak to Attribute_to_gnu Eric Botcazou
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).