aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/libgnat/a-crbltr.ads
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@adacore.com>2020-07-16 12:38:10 -0400
committerPierre-Marie de Rodat <derodat@adacore.com>2020-10-20 03:21:41 -0400
commit66b69678563a18c87985456c797b397676094ff0 (patch)
tree83e52c300516a117442a7be1c8e5b18940f69ba0 /gcc/ada/libgnat/a-crbltr.ads
parent6af3576f431fa716c3a88197355cf1f5ee682ae2 (diff)
downloadgcc-66b69678563a18c87985456c797b397676094ff0.zip
gcc-66b69678563a18c87985456c797b397676094ff0.tar.gz
gcc-66b69678563a18c87985456c797b397676094ff0.tar.bz2
[Ada] New warning on not fully initialized box aggregate
gcc/ada/ * sem_aggr.adb (Resolve_Aggregate): Warn on not fully initialized box aggregate. * sem_aggr.ads: Fix typo. * sem_res.adb (Resolve_Actuals): Fix typo in error message format marking it incorrectly as a continuation message. * sem_elab.adb (Check_Internal_Call_Continue): Similarly, add missing primary message in case of a call to an actual generic subprogram. * sem_warn.adb (Check_References): Do not warn on read but never assigned variables if the type is partially initialized. * libgnat/a-except.ads, libgnat/a-ststun.ads, libgnat/g-sechas.ads, libgnat/a-cbdlli.ads, libgnat/a-cfdlli.ads, libgnat/a-cobove.ads, libgnat/a-cohata.ads, libgnat/a-crbltr.ads, libgnat/a-cbmutr.ads, libgnat/a-crdlli.ads, libgnat/a-cbsyqu.ads: Address new warning. * doc/gnat_ugn/building_executable_programs_with_gnat.rst: Update doc on -gnatwv. * gnat_ugn.texi: Regenerate. gcc/testsuite/ * gnat.dg/opt11.adb: Add new expected warning.
Diffstat (limited to 'gcc/ada/libgnat/a-crbltr.ads')
-rw-r--r--gcc/ada/libgnat/a-crbltr.ads6
1 files changed, 2 insertions, 4 deletions
diff --git a/gcc/ada/libgnat/a-crbltr.ads b/gcc/ada/libgnat/a-crbltr.ads
index 0ae2abd..4f00bd6 100644
--- a/gcc/ada/libgnat/a-crbltr.ads
+++ b/gcc/ada/libgnat/a-crbltr.ads
@@ -60,9 +60,7 @@ package Ada.Containers.Red_Black_Trees is
-- Note that objects of type Tree_Type are logically initialized (in the
-- sense that representation invariants of type are satisfied by dint of
-- default initialization), even without the Nodes component also having
- -- its own initialization expression. We only initializae the Nodes
- -- component here in order to prevent spurious compiler warnings about
- -- the container object not being fully initialized.
+ -- its own initialization expression.
type Tree_Type (Capacity : Count_Type) is tagged record
First : Count_Type := 0;
@@ -71,7 +69,7 @@ package Ada.Containers.Red_Black_Trees is
Length : Count_Type := 0;
TC : aliased Helpers.Tamper_Counts;
Free : Count_Type'Base := -1;
- Nodes : Nodes_Type (1 .. Capacity) := (others => <>);
+ Nodes : Nodes_Type (1 .. Capacity);
end record;
package Implementation is new Helpers.Generic_Implementation;