is
Base_Typ : constant Entity_Id := Base_Type (Typ);
Ent : constant Entity_Id := TSS (Typ, Nam);
-
- function Is_Available (Entity : RE_Id) return Boolean;
- pragma Inline (Is_Available);
- -- Function to check whether the specified run-time call is available
- -- in the run time used. In the case of a configurable run time, it
- -- is normal that some subprograms are not there.
- --
- -- I don't understand this routine at all, why is this not just a
- -- call to RTE_Available? And if for some reason we need a different
- -- routine with different semantics, why is not in Rtsfind ???
-
- ------------------
- -- Is_Available --
- ------------------
-
- function Is_Available (Entity : RE_Id) return Boolean is
- begin
- -- Assume that the unit will always be available when using a
- -- "normal" (not configurable) run time.
-
- return not Configurable_Run_Time_Mode or else RTE_Available (Entity);
- end Is_Available;
-
- -- Start of processing for Find_Stream_Subprogram
-
begin
if Present (Ent) then
return Ent;
-- that stream routines for string types are not present (they require
-- file system support). In this case, the specific stream routines for
-- strings are not used, relying on the regular stream mechanism
- -- instead. That is why we include the test Is_Available when dealing
+ -- instead. That is why we include the test RTE_Available when dealing
-- with these cases.
if not Is_Predefined_Unit (Current_Sem_Unit) then
if Restriction_Active (No_Stream_Optimizations) then
if Nam = TSS_Stream_Input
- and then Is_Available (RE_Storage_Array_Input)
+ and then RTE_Available (RE_Storage_Array_Input)
then
return RTE (RE_Storage_Array_Input);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_Storage_Array_Output)
+ and then RTE_Available (RE_Storage_Array_Output)
then
return RTE (RE_Storage_Array_Output);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_Storage_Array_Read)
+ and then RTE_Available (RE_Storage_Array_Read)
then
return RTE (RE_Storage_Array_Read);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_Storage_Array_Write)
+ and then RTE_Available (RE_Storage_Array_Write)
then
return RTE (RE_Storage_Array_Write);
else
if Nam = TSS_Stream_Input
- and then Is_Available (RE_Storage_Array_Input_Blk_IO)
+ and then RTE_Available (RE_Storage_Array_Input_Blk_IO)
then
return RTE (RE_Storage_Array_Input_Blk_IO);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_Storage_Array_Output_Blk_IO)
+ and then RTE_Available (RE_Storage_Array_Output_Blk_IO)
then
return RTE (RE_Storage_Array_Output_Blk_IO);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_Storage_Array_Read_Blk_IO)
+ and then RTE_Available (RE_Storage_Array_Read_Blk_IO)
then
return RTE (RE_Storage_Array_Read_Blk_IO);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_Storage_Array_Write_Blk_IO)
+ and then RTE_Available (RE_Storage_Array_Write_Blk_IO)
then
return RTE (RE_Storage_Array_Write_Blk_IO);
if Restriction_Active (No_Stream_Optimizations) then
if Nam = TSS_Stream_Input
- and then Is_Available (RE_Stream_Element_Array_Input)
+ and then RTE_Available (RE_Stream_Element_Array_Input)
then
return RTE (RE_Stream_Element_Array_Input);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_Stream_Element_Array_Output)
+ and then RTE_Available (RE_Stream_Element_Array_Output)
then
return RTE (RE_Stream_Element_Array_Output);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_Stream_Element_Array_Read)
+ and then RTE_Available (RE_Stream_Element_Array_Read)
then
return RTE (RE_Stream_Element_Array_Read);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_Stream_Element_Array_Write)
+ and then RTE_Available (RE_Stream_Element_Array_Write)
then
return RTE (RE_Stream_Element_Array_Write);
else
if Nam = TSS_Stream_Input
- and then Is_Available (RE_Stream_Element_Array_Input_Blk_IO)
+ and then RTE_Available (RE_Stream_Element_Array_Input_Blk_IO)
then
return RTE (RE_Stream_Element_Array_Input_Blk_IO);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_Stream_Element_Array_Output_Blk_IO)
+ and then RTE_Available (RE_Stream_Element_Array_Output_Blk_IO)
then
return RTE (RE_Stream_Element_Array_Output_Blk_IO);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_Stream_Element_Array_Read_Blk_IO)
+ and then RTE_Available (RE_Stream_Element_Array_Read_Blk_IO)
then
return RTE (RE_Stream_Element_Array_Read_Blk_IO);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_Stream_Element_Array_Write_Blk_IO)
+ and then RTE_Available (RE_Stream_Element_Array_Write_Blk_IO)
then
return RTE (RE_Stream_Element_Array_Write_Blk_IO);
if Restriction_Active (No_Stream_Optimizations) then
if Nam = TSS_Stream_Input
- and then Is_Available (RE_String_Input)
+ and then RTE_Available (RE_String_Input)
then
return RTE (RE_String_Input);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_String_Output)
+ and then RTE_Available (RE_String_Output)
then
return RTE (RE_String_Output);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_String_Read)
+ and then RTE_Available (RE_String_Read)
then
return RTE (RE_String_Read);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_String_Write)
+ and then RTE_Available (RE_String_Write)
then
return RTE (RE_String_Write);
else
if Nam = TSS_Stream_Input
- and then Is_Available (RE_String_Input_Blk_IO)
+ and then RTE_Available (RE_String_Input_Blk_IO)
then
return RTE (RE_String_Input_Blk_IO);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_String_Output_Blk_IO)
+ and then RTE_Available (RE_String_Output_Blk_IO)
then
return RTE (RE_String_Output_Blk_IO);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_String_Read_Blk_IO)
+ and then RTE_Available (RE_String_Read_Blk_IO)
then
return RTE (RE_String_Read_Blk_IO);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_String_Write_Blk_IO)
+ and then RTE_Available (RE_String_Write_Blk_IO)
then
return RTE (RE_String_Write_Blk_IO);
if Restriction_Active (No_Stream_Optimizations) then
if Nam = TSS_Stream_Input
- and then Is_Available (RE_Wide_String_Input)
+ and then RTE_Available (RE_Wide_String_Input)
then
return RTE (RE_Wide_String_Input);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_Wide_String_Output)
+ and then RTE_Available (RE_Wide_String_Output)
then
return RTE (RE_Wide_String_Output);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_Wide_String_Read)
+ and then RTE_Available (RE_Wide_String_Read)
then
return RTE (RE_Wide_String_Read);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_Wide_String_Write)
+ and then RTE_Available (RE_Wide_String_Write)
then
return RTE (RE_Wide_String_Write);
else
if Nam = TSS_Stream_Input
- and then Is_Available (RE_Wide_String_Input_Blk_IO)
+ and then RTE_Available (RE_Wide_String_Input_Blk_IO)
then
return RTE (RE_Wide_String_Input_Blk_IO);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_Wide_String_Output_Blk_IO)
+ and then RTE_Available (RE_Wide_String_Output_Blk_IO)
then
return RTE (RE_Wide_String_Output_Blk_IO);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_Wide_String_Read_Blk_IO)
+ and then RTE_Available (RE_Wide_String_Read_Blk_IO)
then
return RTE (RE_Wide_String_Read_Blk_IO);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_Wide_String_Write_Blk_IO)
+ and then RTE_Available (RE_Wide_String_Write_Blk_IO)
then
return RTE (RE_Wide_String_Write_Blk_IO);
if Restriction_Active (No_Stream_Optimizations) then
if Nam = TSS_Stream_Input
- and then Is_Available (RE_Wide_Wide_String_Input)
+ and then RTE_Available (RE_Wide_Wide_String_Input)
then
return RTE (RE_Wide_Wide_String_Input);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_Wide_Wide_String_Output)
+ and then RTE_Available (RE_Wide_Wide_String_Output)
then
return RTE (RE_Wide_Wide_String_Output);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_Wide_Wide_String_Read)
+ and then RTE_Available (RE_Wide_Wide_String_Read)
then
return RTE (RE_Wide_Wide_String_Read);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_Wide_Wide_String_Write)
+ and then RTE_Available (RE_Wide_Wide_String_Write)
then
return RTE (RE_Wide_Wide_String_Write);
else
if Nam = TSS_Stream_Input
- and then Is_Available (RE_Wide_Wide_String_Input_Blk_IO)
+ and then RTE_Available (RE_Wide_Wide_String_Input_Blk_IO)
then
return RTE (RE_Wide_Wide_String_Input_Blk_IO);
elsif Nam = TSS_Stream_Output
- and then Is_Available (RE_Wide_Wide_String_Output_Blk_IO)
+ and then RTE_Available (RE_Wide_Wide_String_Output_Blk_IO)
then
return RTE (RE_Wide_Wide_String_Output_Blk_IO);
elsif Nam = TSS_Stream_Read
- and then Is_Available (RE_Wide_Wide_String_Read_Blk_IO)
+ and then RTE_Available (RE_Wide_Wide_String_Read_Blk_IO)
then
return RTE (RE_Wide_Wide_String_Read_Blk_IO);
elsif Nam = TSS_Stream_Write
- and then Is_Available (RE_Wide_Wide_String_Write_Blk_IO)
+ and then RTE_Available (RE_Wide_Wide_String_Write_Blk_IO)
then
return RTE (RE_Wide_Wide_String_Write_Blk_IO);