digitalmars.D.bugs - [Issue 17190] New: [REG2.072] isNumeric!string conflict std.traits
- via Digitalmars-d-bugs (38/38) Feb 16 2017 https://issues.dlang.org/show_bug.cgi?id=17190
https://issues.dlang.org/show_bug.cgi?id=17190 Issue ID: 17190 Summary: [REG2.072] isNumeric!string conflict std.traits std.string Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: regression Priority: P1 Component: phobos Assignee: nobody puremagic.com Reporter: jbc.engelen gmail.com Testcase: ```d // RUN: dmd -c test.d import std.string; import std.traits; void foo() { static if (isNumeric!string) {} } ``` When both std.string and std.traits are imported, dmd 2.072 and 2.073 error with: ``` isnum.d(6): Error: std.traits.isNumeric(T) at /Library/D/dmd/src/phobos/std/traits.d(5350) conflicts with std.string.isNumeric(S)(S s, bool bAllowSep = false) if (isSomeString!S || isRandomAccessRange!S && hasSlicing!S && isSomeChar!(ElementType!S) && !isInfinite!S) at /Library/D/dmd/src/phobos/std/string.d(5844) ``` dmd 2.070 and 2.071 compile it fine. I am not sure whether this is a bug or not. Thanks, Johan --
Feb 16 2017