gcc/cp
[official-gcc.git] / gcc / testsuite / gnat.dg / trampoline1.adb
blob065b373f07c73201be079a1c8537ad4052ed81f6
1 -- { dg-do compile }
2 -- { dg-options "-gnatws" }
4 with System; use System;
6 procedure Trampoline1 is
8 A : Integer;
10 function F (I : Integer) return Integer is
11 begin
12 return A + I;
13 end F;
15 CA : System.Address := F'Code_Address;
17 begin
18 if CA = System.Null_Address then
19 raise Program_Error;
20 end if;
21 end;
23 -- { dg-final { scan-assembler-not "GNU-stack.*x" } }