2015-05-22 Eric Botcazou <ebotcazou@adacore.com>
[official-gcc.git] / gcc / ada / s-except.ads
blobe88a1572b2dd03f916ffb51a03bfa287e075be10
1 ------------------------------------------------------------------------------
2 -- --
3 -- GNAT COMPILER COMPONENTS --
4 -- --
5 -- S Y S T E M . E X C E P T I O N S --
6 -- --
7 -- S p e c --
8 -- --
9 -- Copyright (C) 2006-2014, Free Software Foundation, Inc. --
10 -- --
11 -- GNAT is free software; you can redistribute it and/or modify it under --
12 -- terms of the GNU General Public License as published by the Free Soft- --
13 -- ware Foundation; either version 3, or (at your option) any later ver- --
14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
15 -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
16 -- or FITNESS FOR A PARTICULAR PURPOSE. --
17 -- --
18 -- As a special exception under Section 7 of GPL version 3, you are granted --
19 -- additional permissions described in the GCC Runtime Library Exception, --
20 -- version 3.1, as published by the Free Software Foundation. --
21 -- --
22 -- You should have received a copy of the GNU General Public License and --
23 -- a copy of the GCC Runtime Library Exception along with this program; --
24 -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
25 -- <http://www.gnu.org/licenses/>. --
26 -- --
27 -- GNAT was originally developed by the GNAT team at New York University. --
28 -- Extensive contributions were provided by Ada Core Technologies Inc. --
29 -- --
30 ------------------------------------------------------------------------------
32 pragma Compiler_Unit_Warning;
34 package System.Exceptions is
36 pragma Preelaborate;
37 -- To let Ada.Exceptions "with" us and let us "with" Standard_Library
39 ZCX_By_Default : constant Boolean;
40 -- Visible copy to allow Ada.Exceptions to know the exception model
42 private
44 type Require_Body;
45 -- Dummy Taft-amendment type to make it legal (and required) to provide
46 -- a body for this package.
48 -- We do this because this unit used to have a body in earlier versions
49 -- of GNAT, and it causes various bootstrap path problems etc if we remove
50 -- a body, since we may pick up old unwanted bodies.
52 -- Note: we use this standard Ada method of requiring a body rather
53 -- than the cleaner pragma No_Body because System.Exceptions is a compiler
54 -- unit, and older bootstrap compilers do not support pragma No_Body. This
55 -- type can be removed, and s-except.adb can be replaced by a source
56 -- containing just that pragma, when we decide to move to a 2008 compiler
57 -- as the minimal bootstrap compiler version. ???
59 ZCX_By_Default : constant Boolean := System.ZCX_By_Default;
61 Foreign_Exception : exception;
62 pragma Unreferenced (Foreign_Exception);
63 -- This hidden exception is used to represent non-Ada exception to
64 -- Ada handlers. It is in fact referenced by its linking name.
66 end System.Exceptions;