Bug 12961 – Removing private import for std.conv from std.traits causes dmd test suite failure
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-06-22T20:33:30Z
Last change time
2018-07-30T17:16:30Z
Assigned to
No Owner
Creator
Jonathan M Davis
Comments
Comment #0 by issues.dlang — 2014-06-22T20:33:30Z
In https://github.com/D-Programming-Language/phobos/pull/2260 I'm removing the deprecated
alias unsigned = std.conv.unsigned;
from std.traits, and that works fine. However, if I remove the import for std.conv (which was there just to enable that alias), then the dmd test suit fails
../src/dmd -m64 -Irunnable -odtest_results/runnable -oftest_results/runnable/testaa2_0 runnable/testaa2.d
runnable/testaa2.d(242): Error: associative array key type S does not have 'const int opCmp(ref const S)' member function
The are no imports for std.conv or std.traits in that file. The only module-level import is std.math. std.math _does_ import std.traits, but it does so privately. Adding an import to std.conv in test3825x (the failing test) makes it so that it passes again (in spite of the fact that it isn't using anything from std.conv).
I'm going to leave the import for std.conv in std.traits for the moment, since I have no idea what other impacts removing it will have, but there's definitely something bizarre going on here. Removing the import for std.conv from std.traits should have no impact on anything outside of std.traits.
Comment #1 by github-bugzilla — 2014-06-22T21:25:23Z