Package import order with extern(C++) classes and std.container.array failure
MoonlightSentinel
moonlightsentinel at disroot.org
Tue Apr 6 19:05:29 UTC 2021
On Tuesday, 6 April 2021 at 09:33:32 UTC, cc wrote:
> Just encountered this compilation failure in DMD winx64 2.096,
> which previously worked in 2.095 and prior versions.
DMD 2.094.2 fails with the same error?
But current master works for me.
> Just wondering if it's a bug, or a new issue to keep in mind
> when importing modules? Sorry for the complex nature of this
> scenario but I'll try to keep it as simple as possible.
That's a bug, ordering of import should never affect whether some
code compiles or not.
> I'm curious why this worked in prior dmd versions, and if it's
> something I'll need to worry about going forward when creating
> complex multi-file modules.
The ordering of imports can make a difference in some cases
because it affects the order in which dmd analyses declarations -
which might hide or reveal a bug.
Please file a bug report at https://issues.dlang.org if you
encounter such issues.
More information about the Digitalmars-d-learn
mailing list