Closed simonjwright closed 7 years ago
Awesome, thank you very much for this fix, but also for the helpful explanation, @simonjwright!
Glad to help!
I think if I’d been writing gprbuild
I’d have gone with Ada.Containers.Vectors
throughout rather than GNAT.Dynamic_Tables
.
Oh assuredly. The original implementation was heavily derived from GNAT's own Ada frontend infrastructure, which has driven the design choices. But in parallel to using the current gpr engine, we are working on a long-term evolution of it, based on langkit. It is on our list to put the current WIP state on github, which should hopefully happen soon. The new system indeed makes use of various Containers.
This proposed change is in response to AdaCore/xmlada#3, where building a relocatable library using a recent gprbuild built with GNAT GPL 2016 (or GCC 6.1.0) resulted in
This problem arose with 5f98f94, where
Temp_Files
was added togpr.adb
but not initialized (i.e. only default-initialized). Other instances ofGNAT.Dynamic_Tables
are used in the code, but they are all initialized (usingGNAT.Dynamic_Tables.Init
). It appears that a default-initialized instance works without an explicitInit
in GCC 7, and, I’m sure, AdaCore’s current compilers.