A short-circuit was added in gigi for E_Abstract_State but it results in an 
unbalanced handling of the context.

Tested on x86_64-suse-linux, applied on the mainline.


2015-03-16  Eric Botcazou  <ebotca...@adacore.com>

        * gcc-interface/decl.c (gnat_to_gnu_entity) <E_Abstract_State>: Do not
        short-circuit the regular handling.

-- 
Eric Botcazou
Index: gcc-interface/decl.c
===================================================================
--- gcc-interface/decl.c	(revision 221407)
+++ gcc-interface/decl.c	(working copy)
@@ -4800,9 +4800,11 @@ gnat_to_gnu_entity (Entity_Id gnat_entit
 
     case E_Abstract_State:
       /* This is a SPARK annotation that only reaches here when compiling in
-	 ASIS mode and has no characteristics to annotate.  */
+	 ASIS mode.  */
       gcc_assert (type_annotate_only);
-      return error_mark_node;
+      gnu_decl = error_mark_node;
+      saved = true;
+      break;
 
     default:
       gcc_unreachable ();

Reply via email to