diff options
Diffstat (limited to 'exception_test/exception_test.adb')
-rw-r--r-- | exception_test/exception_test.adb | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/exception_test/exception_test.adb b/exception_test/exception_test.adb new file mode 100644 index 0000000..47fe592 --- /dev/null +++ b/exception_test/exception_test.adb @@ -0,0 +1,20 @@ +-- +-- $Id$ +-- + +with Ada.Text_IO; use Ada.Text_IO; + +procedure ExceptionTest is +begin + begin + Put_Line ("Raising Constraint_Error"); + raise Constraint_Error; + exception + when others => + Put_Line ("Caught Constraint_Error -- inner"); + end; +exception + when others => + Put_Line ("Caught Constraint_Error -- outer -- not OK"); +end ExceptionTest; + |