compiler: give error for non-int arguments to make
[official-gcc.git] / gcc / testsuite / gnat.dg / trampoline3.adb
blob280576624524c18600594eaa1791fc6993ad3e0d
1 -- { dg-do compile { target *-*-linux* } }
2 -- { dg-options "-gnatws" }
4 procedure Trampoline3 is
6 A : Integer;
8 type FuncPtr is access function (I : Integer) return Integer;
10 function F (I : Integer) return Integer is
11 begin
12 return A + I;
13 end F;
15 P : FuncPtr := F'Access;
16 I : Integer;
18 begin
19 I := P(0);
20 end;
22 -- { dg-final { scan-assembler-not "GNU-stack.*x" } }