Commit 49d140bb by Arnaud Charlet

[multiple changes]

2010-06-14  Gary Dismukes  <dismukes@adacore.com>

	* sem_ch4.adb: Fix typo.

2010-06-14  Vasiliy Fofanov  <fofanov@adacore.com>

	* s-oscons-tmplt.c (IOV_MAX): redefine on Tru64 and VMS since the
	vector IO doesn't work at default value properly.

2010-06-14  Doug Rupp  <rupp@adacore.com>

	* s-stoele.adb: Remove unnecessary qualification of To_Address for VMS.

2010-06-14  Vincent Celier  <celier@adacore.com>

	* gnatcmd.adb (Check_Files): Do not invoke the tool with all the
	sources of the project if a switch -files= is used.

2010-06-14  Thomas Quinot  <quinot@adacore.com>

	* exp_attr.adb: Minor reformatting

From-SVN: r160714
parent 7415029d
2010-06-14 Gary Dismukes <dismukes@adacore.com> 2010-06-14 Gary Dismukes <dismukes@adacore.com>
* sem_ch4.adb: Fix typo.
2010-06-14 Vasiliy Fofanov <fofanov@adacore.com>
* s-oscons-tmplt.c (IOV_MAX): redefine on Tru64 and VMS since the
vector IO doesn't work at default value properly.
2010-06-14 Doug Rupp <rupp@adacore.com>
* s-stoele.adb: Remove unnecessary qualification of To_Address for VMS.
2010-06-14 Vincent Celier <celier@adacore.com>
* gnatcmd.adb (Check_Files): Do not invoke the tool with all the
sources of the project if a switch -files= is used.
2010-06-14 Thomas Quinot <quinot@adacore.com>
* exp_attr.adb: Minor reformatting
2010-06-14 Gary Dismukes <dismukes@adacore.com>
* gnat_ugn.texi: Minor typo fixes and wording changes * gnat_ugn.texi: Minor typo fixes and wording changes
2010-06-14 Ed Schonberg <schonberg@adacore.com> 2010-06-14 Ed Schonberg <schonberg@adacore.com>
......
...@@ -3586,8 +3586,7 @@ package body Exp_Attr is ...@@ -3586,8 +3586,7 @@ package body Exp_Attr is
Attribute_Name => Name_First, Attribute_Name => Name_First,
Prefix => New_Occurrence_Of (Ptyp, Loc))))), Prefix => New_Occurrence_Of (Ptyp, Loc))))),
Right_Opnd => Right_Opnd => Make_Integer_Literal (Loc, 1)));
Make_Integer_Literal (Loc, 1)));
Analyze_And_Resolve (N, Typ); Analyze_And_Resolve (N, Typ);
...@@ -3707,7 +3706,7 @@ package body Exp_Attr is ...@@ -3707,7 +3706,7 @@ package body Exp_Attr is
Rewrite (N, Rewrite (N,
Make_Assignment_Statement (Loc, Make_Assignment_Statement (Loc,
Name => Lhs, Name => Lhs,
Expression => Rhs)); Expression => Rhs));
Analyze (N); Analyze (N);
...@@ -3785,9 +3784,7 @@ package body Exp_Attr is ...@@ -3785,9 +3784,7 @@ package body Exp_Attr is
-- the context of a _Postcondition function with a _Result parameter. -- the context of a _Postcondition function with a _Result parameter.
when Attribute_Result => when Attribute_Result =>
Rewrite (N, Rewrite (N, Make_Identifier (Loc, Chars => Name_uResult));
Make_Identifier (Loc,
Chars => Name_uResult));
Analyze_And_Resolve (N, Typ); Analyze_And_Resolve (N, Typ);
----------- -----------
......
...@@ -209,9 +209,9 @@ procedure GNATCmd is ...@@ -209,9 +209,9 @@ procedure GNATCmd is
procedure Check_Files; procedure Check_Files;
-- For GNAT LIST, GNAT PRETTY, GNAT METRIC, and GNAT STACK, check if a -- For GNAT LIST, GNAT PRETTY, GNAT METRIC, and GNAT STACK, check if a
-- project file is specified, without any file arguments. If it is the -- project file is specified, without any file arguments and without a
-- case, invoke the GNAT tool with the proper list of files, derived from -- switch -files=. If it is the case, invoke the GNAT tool with the proper
-- the sources of the project. -- list of files, derived from the sources of the project.
function Check_Project function Check_Project
(Project : Project_Id; (Project : Project_Id;
...@@ -314,10 +314,17 @@ procedure GNATCmd is ...@@ -314,10 +314,17 @@ procedure GNATCmd is
Success : Boolean; Success : Boolean;
begin begin
-- Check if there is at least one argument that is not a switch -- Check if there is at least one argument that is not a switch or if
-- there is a -files= switch.
for Index in 1 .. Last_Switches.Last loop for Index in 1 .. Last_Switches.Last loop
if Last_Switches.Table (Index) (1) /= '-' then if Last_Switches.Table (Index).all'Length > 7 and then
Last_Switches.Table (Index) (1 .. 7) = "-files="
then
Add_Sources := False;
exit;
elsif Last_Switches.Table (Index) (1) /= '-' then
if Index = 1 if Index = 1
or else or else
(The_Command = Check (The_Command = Check
...@@ -346,8 +353,8 @@ procedure GNATCmd is ...@@ -346,8 +353,8 @@ procedure GNATCmd is
end if; end if;
end loop; end loop;
-- If all arguments were switches, add the path names of all the sources -- If all arguments are switchesand there is no switch -files=, add the
-- of the main project. -- path names of all the sources of the main project.
if Add_Sources then if Add_Sources then
......
...@@ -98,6 +98,22 @@ pragma Style_Checks ("M32766"); ...@@ -98,6 +98,22 @@ pragma Style_Checks ("M32766");
#include <limits.h> #include <limits.h>
#include <fcntl.h> #include <fcntl.h>
#if defined (__alpha__) && defined (__osf__)
/** Tru64 is unable to do vector IO operations with default value of IOV_MAX,
** so its value is redefined to a small one which is known to work properly.
**/
#undef IOV_MAX
#define IOV_MAX 16
#endif
#if defined (__VMS)
/** VMS is unable to do vector IO operations with default value of IOV_MAX,
** so its value is redefined to a small one which is known to work properly.
**/
#undef IOV_MAX
#define IOV_MAX 16
#endif
#if ! (defined (__vxworks) || defined (__VMS) || defined (__MINGW32__) || \ #if ! (defined (__vxworks) || defined (__VMS) || defined (__MINGW32__) || \
defined (__nucleus__)) defined (__nucleus__))
# define HAVE_TERMIOS # define HAVE_TERMIOS
......
...@@ -39,7 +39,7 @@ package body System.Storage_Elements is ...@@ -39,7 +39,7 @@ package body System.Storage_Elements is
-- Conversion to/from address -- Conversion to/from address
-- Note full qualification below of To_Address to avoid ambiguities on VMS. -- Note qualification below of To_Address to avoid ambiguities on VMS.
function To_Address is function To_Address is
new Ada.Unchecked_Conversion (Storage_Offset, Address); new Ada.Unchecked_Conversion (Storage_Offset, Address);
...@@ -65,25 +65,25 @@ package body System.Storage_Elements is ...@@ -65,25 +65,25 @@ package body System.Storage_Elements is
function "+" (Left : Address; Right : Storage_Offset) return Address is function "+" (Left : Address; Right : Storage_Offset) return Address is
begin begin
return System.Storage_Elements.To_Address return Storage_Elements.To_Address
(To_Integer (Left) + To_Integer (To_Address (Right))); (To_Integer (Left) + To_Integer (To_Address (Right)));
end "+"; end "+";
function "+" (Left : Storage_Offset; Right : Address) return Address is function "+" (Left : Storage_Offset; Right : Address) return Address is
begin begin
return System.Storage_Elements.To_Address return Storage_Elements.To_Address
(To_Integer (To_Address (Left)) + To_Integer (Right)); (To_Integer (To_Address (Left)) + To_Integer (Right));
end "+"; end "+";
function "-" (Left : Address; Right : Storage_Offset) return Address is function "-" (Left : Address; Right : Storage_Offset) return Address is
begin begin
return System.Storage_Elements.To_Address return Storage_Elements.To_Address
(To_Integer (Left) - To_Integer (To_Address (Right))); (To_Integer (Left) - To_Integer (To_Address (Right)));
end "-"; end "-";
function "-" (Left, Right : Address) return Storage_Offset is function "-" (Left, Right : Address) return Storage_Offset is
begin begin
return To_Offset (System.Storage_Elements.To_Address return To_Offset (Storage_Elements.To_Address
(To_Integer (Left) - To_Integer (Right))); (To_Integer (Left) - To_Integer (Right)));
end "-"; end "-";
......
...@@ -6094,7 +6094,7 @@ package body Sem_Ch4 is ...@@ -6094,7 +6094,7 @@ package body Sem_Ch4 is
First_Actual : Node_Id; First_Actual : Node_Id;
begin begin
-- Place the name of the operation, with its innterpretations, -- Place the name of the operation, with its interpretations,
-- on the rewritten call. -- on the rewritten call.
Set_Name (Call_Node, Subprog); Set_Name (Call_Node, Subprog);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment