[multiple changes]
2013-04-12 Hristian Kirtchev <kirtchev@adacore.com> * sem_prag.adb (Analyze_Input_List): Detect an illegal dependency clause where both input and output lists are null. (Analyze_Pragma): Update the grammar of pragma Depends. 2013-04-12 Vincent Celier <celier@adacore.com> * gnatbind.adb (No_Restriction_List): Exclude restrictions that take a parameter value, not a count. * prj.ads, prj.adb (Remove_All_Restricted_Languages): New procedure. * projects.texi: Complete documentation of attribute Roots. 2013-04-12 Thomas Quinot <quinot@adacore.com> * exp_ch3.adb, exp_util.ads, checks.adb, freeze.adb, sem_attr.adb, sem_ch3.adb: Minor reformatting. * exp_ch4.adb (Size_In_Storage_Elements): Minor documentation improvement: note that the computation is pessimistic for bit packed arrays. * gnat_rm.texi (Range_Length): Fix minor error in description of attribute. From-SVN: r197912
This commit is contained in:
parent
d62520f3cf
commit
ce532f42a7
|
@ -1,3 +1,26 @@
|
|||
2013-04-12 Hristian Kirtchev <kirtchev@adacore.com>
|
||||
|
||||
* sem_prag.adb (Analyze_Input_List): Detect an illegal dependency
|
||||
clause where both input and output lists are null.
|
||||
(Analyze_Pragma): Update the grammar of pragma Depends.
|
||||
|
||||
2013-04-12 Vincent Celier <celier@adacore.com>
|
||||
|
||||
* gnatbind.adb (No_Restriction_List): Exclude restrictions that
|
||||
take a parameter value, not a count.
|
||||
* prj.ads, prj.adb (Remove_All_Restricted_Languages): New procedure.
|
||||
* projects.texi: Complete documentation of attribute Roots.
|
||||
|
||||
2013-04-12 Thomas Quinot <quinot@adacore.com>
|
||||
|
||||
* exp_ch3.adb, exp_util.ads, checks.adb, freeze.adb, sem_attr.adb,
|
||||
sem_ch3.adb: Minor reformatting.
|
||||
* exp_ch4.adb (Size_In_Storage_Elements): Minor documentation
|
||||
improvement: note that the computation is pessimistic for bit
|
||||
packed arrays.
|
||||
* gnat_rm.texi (Range_Length): Fix minor error in description
|
||||
of attribute.
|
||||
|
||||
2013-04-12 Hristian Kirtchev <kirtchev@adacore.com>
|
||||
|
||||
* aspects.adb (Find_Aspect): New routine.
|
||||
|
|
|
@ -996,7 +996,7 @@ package body Checks is
|
|||
elsif Dsiz <= Standard_Long_Long_Integer_Size then
|
||||
Ctyp := Standard_Long_Long_Integer;
|
||||
|
||||
-- No check type exists, use runtime call
|
||||
-- No check type exists, use runtime call
|
||||
|
||||
else
|
||||
if Nkind (N) = N_Op_Add then
|
||||
|
|
|
@ -2780,8 +2780,8 @@ package body Exp_Ch3 is
|
|||
|
||||
-- Loop through components, skipping pragmas, in 2 steps. The first
|
||||
-- step deals with regular components. The second step deals with
|
||||
-- components have per object constraints, and no explicit initia-
|
||||
-- lization.
|
||||
-- components that have per object constraints and no explicit
|
||||
-- initialization.
|
||||
|
||||
Has_POC := False;
|
||||
|
||||
|
@ -2799,9 +2799,7 @@ package body Exp_Ch3 is
|
|||
-- Leave any processing of per-object constrained component for
|
||||
-- the second pass.
|
||||
|
||||
if Has_Access_Constraint (Id)
|
||||
and then No (Expression (Decl))
|
||||
then
|
||||
if Has_Access_Constraint (Id) and then No (Expression (Decl)) then
|
||||
Has_POC := True;
|
||||
|
||||
-- Regular component cases
|
||||
|
|
|
@ -4149,6 +4149,10 @@ package body Exp_Ch4 is
|
|||
-- are too large, and which in the absence of a check results in
|
||||
-- undetected chaos ???
|
||||
|
||||
-- Note in particular that this is a pessimistic estimate in the
|
||||
-- case of packed array types, where an array element might occupy
|
||||
-- just a fraction of a storage element???
|
||||
|
||||
declare
|
||||
Len : Node_Id;
|
||||
Res : Node_Id;
|
||||
|
|
|
@ -345,7 +345,7 @@ package Exp_Util is
|
|||
-- This procedure ensures that type referenced by Typ is defined. For the
|
||||
-- case of a type other than an Itype, nothing needs to be done, since
|
||||
-- all such types have declaration nodes. For Itypes, an N_Itype_Reference
|
||||
-- node is generated and inserted at the given node N. This is typically
|
||||
-- node is generated and inserted as an action on node N. This is typically
|
||||
-- used to ensure that an Itype is properly defined outside a conditional
|
||||
-- construct when it is referenced in more than one branch.
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
-- --
|
||||
-- B o d y --
|
||||
-- --
|
||||
-- Copyright (C) 1992-2012, Free Software Foundation, Inc. --
|
||||
-- Copyright (C) 1992-2013, 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- --
|
||||
|
@ -3484,7 +3484,7 @@ package body Freeze is
|
|||
Set_Is_Packed (Btyp);
|
||||
Set_Has_Non_Standard_Rep (Btyp);
|
||||
|
||||
-- Otherwise give an error message
|
||||
-- Otherwise give an error message
|
||||
|
||||
else
|
||||
Error_Msg_NE
|
||||
|
|
|
@ -7135,7 +7135,7 @@ what is passed to @code{Allocate} and returned from @code{Deallocate}.
|
|||
the number of values represented by the subtype (zero for a null
|
||||
range). The result is static for static subtypes. @code{Range_Length}
|
||||
applied to the index subtype of a one dimensional array always gives the
|
||||
same result as @code{Range} applied to the array itself.
|
||||
same result as @code{Length} applied to the array itself.
|
||||
|
||||
@node Ref
|
||||
@unnumberedsec Ref
|
||||
|
|
|
@ -176,6 +176,15 @@ procedure Gnatbind is
|
|||
Max_Storage_At_Blocking => True,
|
||||
-- Not checkable at compile time
|
||||
|
||||
No_Specification_Of_Aspect => True,
|
||||
-- Requires a parameter value, not a count
|
||||
|
||||
No_Use_Of_Attribute => True,
|
||||
-- Requires a parameter value, not a count
|
||||
|
||||
No_Use_Of_Pragma => True,
|
||||
-- Requires a parameter value, not a count
|
||||
|
||||
others => False);
|
||||
|
||||
Additional_Restrictions_Listed : Boolean := False;
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
-- --
|
||||
-- B o d y --
|
||||
-- --
|
||||
-- Copyright (C) 2001-2012, Free Software Foundation, Inc. --
|
||||
-- Copyright (C) 2001-2013, 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- --
|
||||
|
@ -112,6 +112,15 @@ package body Prj is
|
|||
new Restricted_Lang'(Name => Name_Find, Next => Restricted_Languages);
|
||||
end Add_Restricted_Language;
|
||||
|
||||
-------------------------------------
|
||||
-- Remove_All_Restricted_Languages --
|
||||
-------------------------------------
|
||||
|
||||
procedure Remove_All_Restricted_Languages is
|
||||
begin
|
||||
Restricted_Languages := null;
|
||||
end Remove_All_Restricted_Languages;
|
||||
|
||||
-------------------
|
||||
-- Add_To_Buffer --
|
||||
-------------------
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
-- --
|
||||
-- S p e c --
|
||||
-- --
|
||||
-- Copyright (C) 2001-2012, Free Software Foundation, Inc. --
|
||||
-- Copyright (C) 2001-2013, 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- --
|
||||
|
@ -45,6 +45,10 @@ package Prj is
|
|||
-- Call by gprbuild for each language specify by switch
|
||||
-- --restricted-to-languages=.
|
||||
|
||||
procedure Remove_All_Restricted_Languages;
|
||||
-- Call by gprbuild in CodePeer mode to ignore switches
|
||||
-- --restricted-to-languages=.
|
||||
|
||||
function Is_Allowed_Language (Name : Name_Id) return Boolean;
|
||||
-- Returns True if --restricted-to-languages= is not used or if Name
|
||||
-- is one of the restricted languages.
|
||||
|
@ -1829,6 +1833,7 @@ package Prj is
|
|||
|
||||
Gprbuild_Flags : constant Processing_Flags;
|
||||
Gprclean_Flags : constant Processing_Flags;
|
||||
Gprexec_Flags : constant Processing_Flags;
|
||||
Gnatmake_Flags : constant Processing_Flags;
|
||||
-- Flags used by the various tools. They all display the error messages
|
||||
-- through Prj.Err.
|
||||
|
@ -2003,6 +2008,18 @@ private
|
|||
Missing_Source_Files => Error,
|
||||
Ignore_Missing_With => False);
|
||||
|
||||
Gprexec_Flags : constant Processing_Flags :=
|
||||
(Report_Error => null,
|
||||
When_No_Sources => Silent,
|
||||
Require_Sources_Other_Lang => False,
|
||||
Allow_Duplicate_Basenames => False,
|
||||
Compiler_Driver_Mandatory => False,
|
||||
Error_On_Unknown_Language => True,
|
||||
Require_Obj_Dirs => Silent,
|
||||
Allow_Invalid_External => Error,
|
||||
Missing_Source_Files => Silent,
|
||||
Ignore_Missing_With => False);
|
||||
|
||||
Gnatmake_Flags : constant Processing_Flags :=
|
||||
(Report_Error => null,
|
||||
When_No_Sources => Error,
|
||||
|
|
|
@ -8986,9 +8986,13 @@ package body Sem_Prag is
|
|||
-- null
|
||||
-- | DEPENDENCY_CLAUSE {, DEPENDENCY_CLAUSE}
|
||||
|
||||
-- DEPENDENCY_CLAUSE ::= OUTPUT_LIST =>[+] INPUT_LIST
|
||||
-- DEPENDENCY_CLAUSE ::=
|
||||
-- OUTPUT_LIST =>[+] INPUT_LIST
|
||||
-- | NULL_DEPENDENCY_CLAUSE
|
||||
|
||||
-- OUTPUT_LIST ::= null | OUTPUT | (OUTPUT {, OUTPUT})
|
||||
-- NULL_DEPENDENCY_CLAUSE ::= null => INPUT_LIST
|
||||
|
||||
-- OUTPUT_LIST ::= OUTPUT | (OUTPUT {, OUTPUT})
|
||||
|
||||
-- INPUT_LIST ::= null | INPUT | (INPUT {, INPUT})
|
||||
|
||||
|
@ -9141,6 +9145,16 @@ package body Sem_Prag is
|
|||
Seen => Inputs_Seen,
|
||||
Null_Seen => Null_Input_Seen);
|
||||
end if;
|
||||
|
||||
-- Detect an illegal dependency clause of the form
|
||||
|
||||
-- (null =>[+] null)
|
||||
|
||||
if Null_Output_Seen and then Null_Input_Seen then
|
||||
Error_Msg_N
|
||||
("null dependency clause cannot have a null input list",
|
||||
Inputs);
|
||||
end if;
|
||||
end Analyze_Input_List;
|
||||
|
||||
--------------------------
|
||||
|
|
Loading…
Reference in New Issue