Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gnat.dg/noreturn5.adb @ 138:fc828634a951
merge
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 08 Nov 2018 14:17:14 +0900 |
parents | 04ced10e8804 |
children |
line wrap: on
line source
-- { dg-do compile } with Ada.Characters.Handling; use Ada.Characters.Handling; with GNAT.OS_Lib; use GNAT.OS_Lib; with Text_IO; use Text_IO; package body Noreturn5 is procedure Proc (Arg_Line : Wide_String; Keep_Going : Boolean) is begin Put (To_String (Arg_Line)); if Keep_Going then raise Constraint_Error; else OS_Exit (1); end if; exception when Constraint_Error => raise; when others => if Keep_Going then raise Constraint_Error; else OS_Exit (1); end if; end; end Noreturn5;