On 11/3/16 10:49 AM, Johan Engelen wrote:
On Wednesday, 2 November 2016 at 15:13:43 UTC, anonymous wrote:
On Wednesday, 2 November 2016 at 15:08:26 UTC, anonymous wrote:
I confirm, dmd 2.072 can't build dmd 2.071.2, same error, but boot
since master straping works there's probably something that's been
fixed in one or two of these ddmd modules, likely a static ctor...
Maybe after this:
ddmd.attribs was removed
and it was also part of the cycle.
Thanks for the detective work.
I wonder where the bug is: in 2.071 or in 2.072 :)
Any cycles that are "newly discovered" were already there. What was
happening is that the runtime did not detect the cycle, and was
arbitrarily choosing an order for initializing these modules. Either a)
the arbitrary order happened to be right, or b) the order didn't matter.
Most of the time it's b, because most static ctors don't depend on
externally initialized items.
Note that the push to remove imports to packages and instead import more
specific submodules (i.e. import std.range.primitives instead of
std.range) also plays a factor (it's how I discovered the cycles were
broken). I doubt there was much of that in dmd front end.