repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Update .po files.
[official-gcc.git]
/
gcc
/
testsuite
/
gnat.dg
/
round_div.adb
blob
0a79291c3bd68053d0e562589378e8a53eab81c0
1
-- { dg-do run }
2
-- { dg-options "-O3" }
3
procedure
Round_Div
is
4
type
Fixed
is delta
1.0
range
-
2147483648.0
..
2147483647.0
;
5
A
:
Fixed
:=
1.0
;
6
B
:
Fixed
:=
3.0
;
7
C
:
Integer
;
8
function
Divide
(
X
,
Y
:
Fixed
)
return
Integer
is
9
begin
10
return
Integer
(
X
/
Y
);
11
end
;
12
begin
13
C
:=
Divide
(
A
,
B
);
14
if
C
/=
0
then
15
raise
Program_Error
;
16
end if
;
17
end
Round_Div
;