--- /dev/null
+package Fat_Fields is
+ pragma Elaborate_Body;
+ type A is array (Positive range <>) of Boolean;
+ type A_Ptr is access A;
+ P : A_Ptr := null;
+end;
--- /dev/null
+package Global_Constant is
+ pragma Elaborate_Body;
+ An_Error : exception;
+end;
--- /dev/null
+package Non_LValue is
+ type T (Length : Natural) is record
+ A : String (1 .. Length);
+ B : String (1 .. Length);
+ end record;
+ type T_Ptr is access all T;
+ type U is record
+ X : T_Ptr;
+ end record;
+ function A (Y : U) return String;
+end;
--- /dev/null
+package Unc_Constructor is
+ type C is null record;
+ type A is array (Positive range <>) of C;
+ A0 : constant A;
+ procedure P (X : A);
+private
+ A0 : aliased constant A := (1 .. 0 => (null record));
+end;
--- /dev/null
+package Var_Size is
+ type T (Length : Natural) is record
+ A : String (1 .. Length);
+ B : String (1 .. Length);
+ end record;
+ function A (X : T) return String;
+end;
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
procedure Array_Constructor is
A : array (Integer range <>) of Boolean := (True, False);
begin
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
procedure Array_Range_Ref is
A : String (1 .. 3);
B : String := A (A'RANGE)(1 .. 3);
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
procedure Array_Ref is
type A is array (Natural range <>, Natural range <>) of Boolean;
type A_Access is access A;
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
procedure Array_Size is
subtype S is String (1 .. 2);
type R is record
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
with System.Machine_Code;
procedure Asm is
begin
--- RUN: %llvmgcc -c -g %s -o /dev/null
+-- RUN: %llvmgcc -c -g %s
package Debug_Var_Size is
subtype Length_Type is Positive range 1 .. 64;
type T (Length : Length_Type := 1) is record
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
with Ada.Finalization;
package Emit_Var is
type Search_Type is new Ada.Finalization.Controlled with null record;
--- RUN: %llvmgcc -c %s -o /dev/null
--- RUN: %llvmgcc -c %s -O2 -o /dev/null
+-- RUN: %llvmgcc -c %s -I%p/Support
+-- RUN: %llvmgcc -c %s -I%p/Support -O2
package body Fat_Fields is
procedure Proc is
begin
+++ /dev/null
-package Fat_Fields is
- pragma Elaborate_Body;
- type A is array (Positive range <>) of Boolean;
- type A_Ptr is access A;
- P : A_Ptr := null;
-end;
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s -I%p/Support
package body Global_Constant is
begin
raise An_Error;
+++ /dev/null
-package Global_Constant is
- pragma Elaborate_Body;
- An_Error : exception;
-end;
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s -I%p/Support
package body Non_LValue is
function A (Y : U) return String is
begin
+++ /dev/null
-package Non_LValue is
- type T (Length : Natural) is record
- A : String (1 .. Length);
- B : String (1 .. Length);
- end record;
- type T_Ptr is access all T;
- type U is record
- X : T_Ptr;
- end record;
- function A (Y : U) return String;
-end;
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
function Switch (N : Integer) return Integer is
begin
case N is
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s -I%p/Support
package body Unc_Constructor is
procedure P (X : A) is
begin
+++ /dev/null
-package Unc_Constructor is
- type C is null record;
- type A is array (Positive range <>) of C;
- A0 : constant A;
- procedure P (X : A);
-private
- A0 : aliased constant A := (1 .. 0 => (null record));
-end;
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s -I%p/Support
package body Var_Size is
function A (X : T) return String is
begin
+++ /dev/null
-package Var_Size is
- type T (Length : Natural) is record
- A : String (1 .. Length);
- B : String (1 .. Length);
- end record;
- function A (X : T) return String;
-end;
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
procedure VCE is
S : String (1 .. 2);
B : Character := 'B';
--- RUN: %llvmgcc -c %s -o /dev/null
+-- RUN: %llvmgcc -c %s
procedure VCE_LV is
type P is access String ;
type T is new P (5 .. 7);