[multiple changes]
2014-06-13 Robert Dewar <dewar@adacore.com> * back_end.ads, back_end.adb: Make_Id, Make_SC, Set_RND are moved to Tbuild. * tbuild.ads, tbuild.adb: Make_Id, Make_SC, Set_RND are moved here from Back_End. * gnat1drv.adb: Make_Id, Make_SC, Set_RND are moved to Tbuild * sem_warn.adb: Minor reformatting. 2014-06-13 Doug Rupp <rupp@adacore.com> * adaint.c (__gnat_open_new_temp) [VMS]: Open binary files with rfm=udf. From-SVN: r211612
This commit is contained in:
parent
7f2c8954da
commit
5af638c875
@ -1,3 +1,17 @@
|
||||
2014-06-13 Robert Dewar <dewar@adacore.com>
|
||||
|
||||
* back_end.ads, back_end.adb: Make_Id, Make_SC, Set_RND are moved to
|
||||
Tbuild.
|
||||
* tbuild.ads, tbuild.adb: Make_Id, Make_SC, Set_RND are moved here from
|
||||
Back_End.
|
||||
* gnat1drv.adb: Make_Id, Make_SC, Set_RND are moved to Tbuild
|
||||
* sem_warn.adb: Minor reformatting.
|
||||
|
||||
2014-06-13 Doug Rupp <rupp@adacore.com>
|
||||
|
||||
* adaint.c (__gnat_open_new_temp) [VMS]: Open binary
|
||||
files with rfm=udf.
|
||||
|
||||
2014-06-13 Yannick Moy <moy@adacore.com>
|
||||
|
||||
* sem_warn.adb (Check_Unset_References): Take
|
||||
|
@ -6,7 +6,7 @@
|
||||
* *
|
||||
* C Implementation File *
|
||||
* *
|
||||
* Copyright (C) 1992-2013, Free Software Foundation, Inc. *
|
||||
* Copyright (C) 1992-2014, Free Software Foundation, Inc. *
|
||||
* *
|
||||
* GNAT is free software; you can redistribute it and/or modify it under *
|
||||
* terms of the GNU General Public License as published by the Free Soft- *
|
||||
@ -1159,9 +1159,12 @@ __gnat_open_new_temp (char *path, int fmode)
|
||||
o_fmode = O_TEXT;
|
||||
|
||||
#if defined (VMS)
|
||||
/* Passing rfm=stmlf for binary files seems questionable since it results
|
||||
in having an extraneous line feed added after every call to CRTL write,
|
||||
so pass rfm=udf (aka undefined) instead. */
|
||||
fd = open (path, O_WRONLY | O_CREAT | O_EXCL | o_fmode, PERM,
|
||||
"rfm=stmlf", "ctx=rec", "rat=none", "shr=del,get,put,upd",
|
||||
"mbc=16", "deq=64", "fop=tef");
|
||||
fmode ? "rfm=stmlf" : "rfm=udf", "ctx=rec", "rat=none",
|
||||
"shr=del,get,put,upd", "mbc=16", "deq=64", "fop=tef");
|
||||
#else
|
||||
fd = open (path, O_WRONLY | O_CREAT | O_EXCL | o_fmode, PERM);
|
||||
#endif
|
||||
|
@ -24,7 +24,6 @@
|
||||
------------------------------------------------------------------------------
|
||||
|
||||
with Atree; use Atree;
|
||||
with Csets; use Csets;
|
||||
with Debug; use Debug;
|
||||
with Elists; use Elists;
|
||||
with Errout; use Errout;
|
||||
@ -34,14 +33,13 @@ with Opt; use Opt;
|
||||
with Osint.C; use Osint.C;
|
||||
with Namet; use Namet;
|
||||
with Nlists; use Nlists;
|
||||
with Nmake; use Nmake;
|
||||
with Restrict; use Restrict;
|
||||
with Stand; use Stand;
|
||||
with Sinput; use Sinput;
|
||||
with Stringt; use Stringt;
|
||||
with Switch; use Switch;
|
||||
with Switch.C; use Switch.C;
|
||||
with System; use System;
|
||||
with Types; use Types;
|
||||
|
||||
with System.OS_Lib; use System.OS_Lib;
|
||||
|
||||
@ -189,36 +187,6 @@ package body Back_End is
|
||||
raise Program_Error;
|
||||
end Len_Arg;
|
||||
|
||||
-------------
|
||||
-- Make_Id --
|
||||
-------------
|
||||
|
||||
function Make_Id (Str : Text_Buffer) return Node_Id is
|
||||
begin
|
||||
Name_Len := 0;
|
||||
|
||||
for J in Str'Range loop
|
||||
Name_Len := Name_Len + 1;
|
||||
Name_Buffer (Name_Len) := Fold_Lower (Str (J));
|
||||
end loop;
|
||||
|
||||
return
|
||||
Make_Identifier (System_Location,
|
||||
Chars => Name_Find);
|
||||
end Make_Id;
|
||||
|
||||
-------------
|
||||
-- Make_SC --
|
||||
-------------
|
||||
|
||||
function Make_SC (Pre, Sel : Node_Id) return Node_Id is
|
||||
begin
|
||||
return
|
||||
Make_Selected_Component (System_Location,
|
||||
Prefix => Pre,
|
||||
Selector_Name => Sel);
|
||||
end Make_SC;
|
||||
|
||||
-----------------------------
|
||||
-- Scan_Compiler_Arguments --
|
||||
-----------------------------
|
||||
@ -383,13 +351,4 @@ package body Back_End is
|
||||
end loop;
|
||||
end Scan_Compiler_Arguments;
|
||||
|
||||
-------------
|
||||
-- Set_RND --
|
||||
-------------
|
||||
|
||||
procedure Set_RND (Unit : Node_Id) is
|
||||
begin
|
||||
Restrict.Set_Restriction_No_Dependence (Unit, Warn => False);
|
||||
end Set_RND;
|
||||
|
||||
end Back_End;
|
||||
|
@ -27,8 +27,6 @@
|
||||
-- Note: there are multiple bodies/variants of this package, so do not
|
||||
-- modify this spec without coordination.
|
||||
|
||||
with Types; use Types;
|
||||
|
||||
package Back_End is
|
||||
|
||||
type Back_End_Mode_Type is (
|
||||
@ -86,13 +84,4 @@ package Back_End is
|
||||
-- object file's timestamp is correct when compared with the corresponding
|
||||
-- ali file by gnatmake.
|
||||
|
||||
function Make_Id (Str : Text_Buffer) return Node_Id;
|
||||
function Make_SC (Pre, Sel : Node_Id) return Node_Id;
|
||||
procedure Set_RND (Unit : Node_Id);
|
||||
-- Subprograms for call to Get_Target_Parameters, see spec of package
|
||||
-- Targparm for full description of these three subprograms. These are
|
||||
-- parked in this package because they are have to be at the top level
|
||||
-- because of accessibility issues, and Gnat1drv, which is where they
|
||||
-- are used, is a subprogram.
|
||||
|
||||
end Back_End;
|
||||
|
@ -69,6 +69,7 @@ with Sprint; use Sprint;
|
||||
with Stringt;
|
||||
with Stylesw; use Stylesw;
|
||||
with Targparm; use Targparm;
|
||||
with Tbuild;
|
||||
with Tree_Gen;
|
||||
with Treepr; use Treepr;
|
||||
with Ttypes;
|
||||
@ -818,9 +819,9 @@ begin
|
||||
(System_Text => Source_Text (S),
|
||||
Source_First => Source_First (S),
|
||||
Source_Last => Source_Last (S),
|
||||
Make_Id => Back_End.Make_Id'Unrestricted_Access,
|
||||
Make_SC => Back_End.Make_SC'Unrestricted_Access,
|
||||
Set_RND => Back_End.Set_RND'Unrestricted_Access);
|
||||
Make_Id => Tbuild.Make_Id'Access,
|
||||
Make_SC => Tbuild.Make_SC'Access,
|
||||
Set_RND => Tbuild.Set_RND'Access);
|
||||
|
||||
-- Acquire configuration pragma information from Targparm
|
||||
|
||||
|
@ -1810,7 +1810,7 @@ package body Sem_Warn is
|
||||
SE : constant Entity_Id := Scope (E);
|
||||
|
||||
function Within_Postcondition return Boolean;
|
||||
-- Returns True iff N is within a Postcondition, a
|
||||
-- Returns True if N is within a Postcondition, a
|
||||
-- Refined_Post, an Ensures component in a Test_Case,
|
||||
-- or a Contract_Cases.
|
||||
|
||||
|
@ -6,7 +6,7 @@
|
||||
-- --
|
||||
-- B o d y --
|
||||
-- --
|
||||
-- Copyright (C) 1992-2013, Free Software Foundation, Inc. --
|
||||
-- Copyright (C) 1992-2014, Free Software Foundation, Inc. --
|
||||
-- --
|
||||
-- GNAT is free software; you can redistribute it and/or modify it under --
|
||||
-- terms of the GNU General Public License as published by the Free Soft- --
|
||||
@ -24,6 +24,7 @@
|
||||
------------------------------------------------------------------------------
|
||||
|
||||
with Atree; use Atree;
|
||||
with Csets; use Csets;
|
||||
with Einfo; use Einfo;
|
||||
with Elists; use Elists;
|
||||
with Lib; use Lib;
|
||||
@ -240,6 +241,24 @@ package body Tbuild is
|
||||
end if;
|
||||
end Make_Float_Literal;
|
||||
|
||||
-------------
|
||||
-- Make_Id --
|
||||
-------------
|
||||
|
||||
function Make_Id (Str : Text_Buffer) return Node_Id is
|
||||
begin
|
||||
Name_Len := 0;
|
||||
|
||||
for J in Str'Range loop
|
||||
Name_Len := Name_Len + 1;
|
||||
Name_Buffer (Name_Len) := Fold_Lower (Str (J));
|
||||
end loop;
|
||||
|
||||
return
|
||||
Make_Identifier (System_Location,
|
||||
Chars => Name_Find);
|
||||
end Make_Id;
|
||||
|
||||
-------------------------------------
|
||||
-- Make_Implicit_Exception_Handler --
|
||||
-------------------------------------
|
||||
@ -459,6 +478,18 @@ package body Tbuild is
|
||||
UI_From_Int (RT_Exception_Code'Pos (Reason)));
|
||||
end Make_Raise_Storage_Error;
|
||||
|
||||
-------------
|
||||
-- Make_SC --
|
||||
-------------
|
||||
|
||||
function Make_SC (Pre, Sel : Node_Id) return Node_Id is
|
||||
begin
|
||||
return
|
||||
Make_Selected_Component (System_Location,
|
||||
Prefix => Pre,
|
||||
Selector_Name => Sel);
|
||||
end Make_SC;
|
||||
|
||||
-------------------------
|
||||
-- Make_String_Literal --
|
||||
-------------------------
|
||||
@ -749,6 +780,15 @@ package body Tbuild is
|
||||
return Result;
|
||||
end OK_Convert_To;
|
||||
|
||||
-------------
|
||||
-- Set_RND --
|
||||
-------------
|
||||
|
||||
procedure Set_RND (Unit : Node_Id) is
|
||||
begin
|
||||
Set_Restriction_No_Dependence (Unit, Warn => False);
|
||||
end Set_RND;
|
||||
|
||||
--------------------------
|
||||
-- Unchecked_Convert_To --
|
||||
--------------------------
|
||||
|
@ -321,4 +321,16 @@ package Tbuild is
|
||||
-- Like Convert_To, but if a conversion is actually needed, constructs an
|
||||
-- N_Unchecked_Type_Conversion node to do the required conversion.
|
||||
|
||||
-------------------------------------
|
||||
-- Subprograms for Use by Gnat1drv --
|
||||
-------------------------------------
|
||||
|
||||
function Make_Id (Str : Text_Buffer) return Node_Id;
|
||||
function Make_SC (Pre, Sel : Node_Id) return Node_Id;
|
||||
procedure Set_RND (Unit : Node_Id);
|
||||
-- Subprograms for call to Get_Target_Parameters in Gnat1drv, see spec
|
||||
-- of package Targparm for full description of these three subprograms.
|
||||
-- These have to be declared at the top level of a package (accessibility
|
||||
-- issues), and Gnat1drv is a procedure, so they can't go there.
|
||||
|
||||
end Tbuild;
|
||||
|
Loading…
Reference in New Issue
Block a user