OSDN Git Service

ada:
[pf3gnuchains/gcc-fork.git] / gcc / ada / a-exexpr.adb
index 13b7d79..cbe8a5c 100644 (file)
@@ -6,7 +6,7 @@
 --                                                                          --
 --                                 B o d y                                  --
 --                                                                          --
---          Copyright (C) 1992-2009, Free Software Foundation, Inc.         --
+--          Copyright (C) 1992-2011, Free Software Foundation, Inc.         --
 --                                                                          --
 -- GNAT is free software;  you can  redistribute it  and/or modify it under --
 -- terms of the  GNU General Public License as published  by the Free Soft- --
 --  This is the default version, using the __builtin_setjmp/longjmp EH
 --  mechanism.
 
-with System.Storage_Elements;  use System.Storage_Elements;
-
-pragma Warnings (Off);
---  Since several constructs give warnings in 3.14a1, including unreferenced
---  variables and pragma Unreferenced itself.
+with Ada.Unchecked_Conversion;
 
 separate (Ada.Exceptions)
 package body Exception_Propagation is
 
-   procedure builtin_longjmp (buffer : Address; Flag : Integer);
-   pragma No_Return (builtin_longjmp);
-   pragma Import (C, builtin_longjmp, "_gnat_builtin_longjmp");
-
-   ---------------------
-   -- Setup_Exception --
-   ---------------------
-
-   procedure Setup_Exception
-     (Excep    : EOA;
-      Current  : EOA;
-      Reraised : Boolean := False)
-   is
-      pragma Unreferenced (Excep, Current, Reraised);
-   begin
-      --  In the GNAT-SJLJ case this "stack" only exists implicitly, by way of
-      --  local occurrence declarations together with save/restore operations
-      --  generated by the front-end, and this routine has nothing to do.
+   --  Common binding to __builtin_longjmp for sjlj variants.
 
-      null;
-   end Setup_Exception;
+   procedure builtin_longjmp (buffer : System.Address; Flag : Integer);
+   pragma No_Return (builtin_longjmp);
+   pragma Import (Intrinsic, builtin_longjmp, "__builtin_longjmp");
 
    -------------------------
    -- Propagate_Exception --
    -------------------------
 
    procedure Propagate_Exception
-     (E                   : Exception_Id;
-      From_Signal_Handler : Boolean)
    is
-      pragma Inspection_Point (E);
-
       Jumpbuf_Ptr : constant Address := Get_Jmpbuf_Address.all;
       Excep       : constant EOA := Get_Current_Excep.all;
    begin