[multiple changes]
2015-10-20 Vincent Celier <celier@adacore.com> * prj-attr.adb: Add package Codepeer and its attributes. 2015-10-20 Thomas Quinot <quinot@adacore.com> * sem_ch3.adb, sem_ch13.adb: Minor reformatting. 2015-10-20 Eric Botcazou <ebotcazou@adacore.com> * gnatlink.adb (Gnatlink): Do not translate --RTS switch for the linker and instead pass the switches that were reinstated by the compiler. 2015-10-20 Bob Duff <duff@adacore.com> * a-contai.ads, a-convec.ads: Move Count_Type_Last from a-convec.ads to a-contai.ads, so other containers can refer to it. From-SVN: r229027
This commit is contained in:
parent
b8a1821614
commit
40417de8ab
|
@ -1,3 +1,22 @@
|
|||
2015-10-20 Vincent Celier <celier@adacore.com>
|
||||
|
||||
* prj-attr.adb: Add package Codepeer and its attributes.
|
||||
|
||||
2015-10-20 Thomas Quinot <quinot@adacore.com>
|
||||
|
||||
* sem_ch3.adb, sem_ch13.adb: Minor reformatting.
|
||||
|
||||
2015-10-20 Eric Botcazou <ebotcazou@adacore.com>
|
||||
|
||||
* gnatlink.adb (Gnatlink): Do not translate --RTS switch
|
||||
for the linker and instead pass the switches that were
|
||||
reinstated by the compiler.
|
||||
|
||||
2015-10-20 Bob Duff <duff@adacore.com>
|
||||
|
||||
* a-contai.ads, a-convec.ads: Move Count_Type_Last from
|
||||
a-convec.ads to a-contai.ads, so other containers can refer to it.
|
||||
|
||||
2015-10-20 Ed Schonberg <schonberg@adacore.com>
|
||||
|
||||
* sem_ch3.adb (Check_Nonoverridable_Aspects): New procedure within
|
||||
|
|
|
@ -34,6 +34,10 @@ package Ada.Containers is
|
|||
|
||||
private
|
||||
|
||||
Count_Type_Last : constant := Count_Type'Last;
|
||||
-- Count_Type'Last as a universal_integer, so we can compare Index_Type
|
||||
-- values against this without type conversions that might overflow.
|
||||
|
||||
type Tamper_Counts is record
|
||||
Busy : Natural := 0;
|
||||
Lock : Natural := 0;
|
||||
|
|
|
@ -370,6 +370,7 @@ private
|
|||
use Implementation;
|
||||
|
||||
type Elements_Array is array (Index_Type range <>) of aliased Element_Type;
|
||||
function "=" (L, R : Elements_Array) return Boolean is abstract;
|
||||
|
||||
type Elements_Type (Last : Extended_Index) is limited record
|
||||
EA : Elements_Array (Index_Type'First .. Last);
|
||||
|
@ -490,10 +491,6 @@ private
|
|||
|
||||
Empty_Vector : constant Vector := (Controlled with others => <>);
|
||||
|
||||
Count_Type_Last : constant := Count_Type'Last;
|
||||
-- Count_Type'Last as a universal_integer, so we can compare Index_Type
|
||||
-- values against this without type conversions that might overflow.
|
||||
|
||||
type Iterator is new Limited_Controlled and
|
||||
Vector_Iterator_Interfaces.Reversible_Iterator with
|
||||
record
|
||||
|
|
|
@ -1539,8 +1539,7 @@ begin
|
|||
loop
|
||||
-- Do not compile with the front end switches. However, --RTS
|
||||
-- is to be dealt with specially because it needs to be passed
|
||||
-- if the binder-generated file is in Ada and may also be used
|
||||
-- to drive the linker.
|
||||
-- to compile the file generated by the binder.
|
||||
|
||||
declare
|
||||
Arg : String_Ptr renames Args.Table (Index);
|
||||
|
@ -1550,6 +1549,31 @@ begin
|
|||
Binder_Options_From_ALI.Table
|
||||
(Binder_Options_From_ALI.Last) := String_Access (Arg);
|
||||
|
||||
-- GNAT doesn't support GCC's multilib mechanism when it
|
||||
-- is configured with --disable-libada. This means that,
|
||||
-- when a multilib switch is used to request a particular
|
||||
-- compilation mode, the corresponding --RTS switch must
|
||||
-- also be specified. It is convenient to eliminate the
|
||||
-- redundancy by keying the compilation mode on a single
|
||||
-- switch, namely --RTS, and have the compiler reinstate
|
||||
-- the multilib switch (see gcc-interface/lang-specs.h).
|
||||
-- This switch must be passed to the driver at link time.
|
||||
|
||||
if Arg'Length = 5
|
||||
and then Arg (Arg'First + 1 .. Arg'First + 4) = "mrtp"
|
||||
then
|
||||
Linker_Options.Increment_Last;
|
||||
Linker_Options.Table
|
||||
(Linker_Options.Last) := String_Access (Arg);
|
||||
|
||||
elsif Arg'Length = 6
|
||||
and then Arg (Arg'First + 1 .. Arg'First + 5) = "fsjlj"
|
||||
then
|
||||
Linker_Options.Increment_Last;
|
||||
Linker_Options.Table
|
||||
(Linker_Options.Last) := String_Access (Arg);
|
||||
end if;
|
||||
|
||||
elsif Arg'Length > 5
|
||||
and then Arg (Arg'First + 2 .. Arg'First + 5) = "RTS="
|
||||
then
|
||||
|
@ -1568,27 +1592,6 @@ begin
|
|||
Opt.RTS_Lib_Path_Name :=
|
||||
Get_RTS_Search_Dir
|
||||
(Arg (Arg'First + 6 .. Arg'Last), Objects);
|
||||
|
||||
-- GNAT doesn't support the GCC multilib mechanism.
|
||||
-- This means that, when a multilib switch is used
|
||||
-- to request a particular compilation mode, the
|
||||
-- corresponding runtime switch (--RTS) must also be
|
||||
-- specified. The long-term goal is to fully support the
|
||||
-- multilib mechanism; however, in the meantime, it is
|
||||
-- convenient to eliminate the redundancy by keying the
|
||||
-- compilation mode on a single switch, namely --RTS.
|
||||
|
||||
-- Pass -mrtp to the linker if --RTS=rtp was passed
|
||||
|
||||
if Arg'Length > 8
|
||||
and then
|
||||
(Arg (Arg'First + 6 .. Arg'First + 8) = "rtp"
|
||||
or else Arg (Arg'Last - 2 .. Arg'Last) = "rtp")
|
||||
then
|
||||
Linker_Options.Increment_Last;
|
||||
Linker_Options.Table (Linker_Options.Last) :=
|
||||
new String'("-mrtp");
|
||||
end if;
|
||||
end if;
|
||||
end;
|
||||
end loop;
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
-- --
|
||||
-- B o d y --
|
||||
-- --
|
||||
-- Copyright (C) 2001-2014, Free Software Foundation, Inc. --
|
||||
-- Copyright (C) 2001-2015, 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- --
|
||||
|
@ -379,6 +379,16 @@ package body Prj.Attr is
|
|||
"Pstack#" &
|
||||
"LVswitches#" &
|
||||
|
||||
-- package Codepeer
|
||||
|
||||
"Pcodepeer#" &
|
||||
"SVoutput_directory#" &
|
||||
"SVdatabase_directory#" &
|
||||
"SVmessage_patterns#" &
|
||||
"SVadditional_patterns#" &
|
||||
"LVswitches#" &
|
||||
"LVexcluded_source_files#" &
|
||||
|
||||
"#";
|
||||
|
||||
Initialized : Boolean := False;
|
||||
|
|
|
@ -1447,9 +1447,6 @@ package body Sem_Ch13 is
|
|||
Disc : Entity_Id;
|
||||
Parent_Disc : Entity_Id;
|
||||
|
||||
-- For a type extension, check whether parent has a
|
||||
-- reference discriminant, to verify that use is proper.
|
||||
|
||||
begin
|
||||
if not Is_Type (E) or else not Has_Discriminants (E) then
|
||||
Error_Msg_N
|
||||
|
@ -1474,7 +1471,7 @@ package body Sem_Ch13 is
|
|||
Next_Discriminant (Disc);
|
||||
end loop;
|
||||
|
||||
-- Error if no proper access discriminant.
|
||||
-- Error if no proper access discriminant
|
||||
|
||||
if No (Disc) then
|
||||
Error_Msg_NE
|
||||
|
@ -1483,6 +1480,9 @@ package body Sem_Ch13 is
|
|||
end if;
|
||||
end if;
|
||||
|
||||
-- For a type extension, check whether parent has a
|
||||
-- reference discriminant, to verify that use is proper.
|
||||
|
||||
if Is_Derived_Type (E)
|
||||
and then Has_Discriminants (Etype (E))
|
||||
then
|
||||
|
|
|
@ -2615,7 +2615,7 @@ package body Sem_Ch3 is
|
|||
return False;
|
||||
end Has_Aspect_Spec;
|
||||
|
||||
-- Start of processing for Check_Nonoverridable_Aspects
|
||||
-- Start of processing for Check_Nonoverridable_Aspects
|
||||
|
||||
begin
|
||||
|
||||
|
|
Loading…
Reference in New Issue