This doesn't ICE with gcc 4.3.1, may be by luck. $ cat pt.ads package PT is
function S (V : in Long_Float) return String; end PT; $ cat pt.adb package body Pt is function Long_Float_Is_Valid (X : in Long_Float) return Boolean is Is_Nan : constant Boolean := X /= X; Is_P_Inf : constant Boolean := X > Long_Float'Last; Is_M_Inf : constant Boolean := X < Long_Float'First; Is_Invalid : constant Boolean := Is_Nan or Is_P_Inf or Is_M_Inf; begin return not Is_Invalid; end Long_Float_Is_Valid; function S (V : in Long_Float) return String is begin if not Long_Float_Is_Valid (V) then return "INVALID"; else return "OK"; end if; exception when others => return "ERROR"; end S; end Pt; $ gcc -c -O2 pt.adb pt.adb: In function 'Pt.S': pt.adb:12: error: BB 2 can not throw but has EH edges pt.adb:12: error: BB 3 can not throw but has EH edges +===========================GNAT BUG DETECTED==============================+ | 4.4.0 20080617 (experimental) [trunk revision 136861] (x86_64-unknown-linux-gnu) GCC error:| | verify_flow_info failed | | Error detected around pt.adb:12 | -- Summary: [4.4 regression] verify_flow_info ICE can not throw but has EH edges Product: gcc Version: 4.4.0 Status: UNCONFIRMED Keywords: ice-on-valid-code Severity: normal Priority: P3 Component: ada AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: laurent at guerby dot net GCC host triplet: x86_64-linux http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36554