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
openmp: Fix signed/unsigned warning
[official-gcc.git]
/
gcc
/
testsuite
/
gnat.dg
/
in_out_parameter2.adb
blob
1b5cc7e6abf6634b2059f090d26a8f56d88367ba
1
-- { dg-do run }
2
-- { dg-options "-gnat12" }
3
4
procedure
In_Out_Parameter2
is
5
6
function
F
(
I
:
In Out
Integer
)
return
Boolean
is
7
A
:
Integer
:=
I
;
8
begin
9
I
:=
I
+
1
;
10
return
(
A
>
0
);
11
end
;
12
13
I
:
Integer
:=
0
;
14
B
:
Boolean
;
15
16
begin
17
B
:=
F
(
I
);
18
if
B
then
19
raise
Program_Error
;
20
end if
;
21
if
I
/=
1
then
22
raise
Program_Error
;
23
end if
;
24
end
;