www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 12961] New: Removing private import for std.conv from


          Issue ID: 12961
           Summary: Removing private import for std.conv from std.traits
                    causes dmd test suite failure
           Product: D
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: DMD
          Assignee: nobody puremagic.com
          Reporter: jmdavisProg gmx.com

In https://github.com/D-Programming-Language/phobos/pull/2260 I'm removing the

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

../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.

Jun 22 2014