1 -- { dg-do run { target *-*-solaris2.* } }
2 -- { dg-options "-ftrapping-math" }
4 procedure FP_Exception
is
6 type my_fixed
is digits 15;
7 for my_fixed
'size use 64;
8 fixed1
: my_fixed
:= 1.0;
9 fixed2
: my_fixed
:= -0.0;
10 mask_all
: constant integer := 16#
1F#
;
12 procedure fpsetmask
(mask
: in integer);
13 pragma IMPORT
(C
, fpsetmask
, "fpsetmask");
17 -- Mask all floating point exceptions so they can be trapped
20 fixed1
:= fixed1
/ fixed2
;