← Back to index
|
Original Bugzilla link
Bug 14149 – Bad std.algorithm error messages
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P2
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2015-02-08T15:54:15Z
Last change time
2018-10-16T19:50:54Z
Keywords
diagnostic
Assigned to
No Owner
Creator
Vladimir Panteleev
Depends on
13372
Comments
Comment #0
by dlang-bugzilla — 2015-02-08T15:54:15Z
///////////// test.d //////////// import std.algorithm.iteration; void main() { reduce!"a+b"("cheese", [42]); } ///////////////////////////////// With DMD head, this prints the errors: C:\...\phobos\std\algorithm\iteration.d(2484,21): Error: undefined identifier algoFormat C:\...\phobos\std\algorithm\iteration.d(2483,17): Error: static assert __error C:\...\phobos\std\algorithm\iteration.d(2469,32): instantiated from here: reduceImpl!(false, int[], string) C:\...\phobos\std\algorithm\iteration.d(2454,33): instantiated from here: reducePreImpl!(int[], string) test.d(5,14): instantiated from here: reduce!(string, int[])
Comment #1
by github-bugzilla — 2015-02-15T15:39:09Z
Commits pushed to master at
https://github.com/D-Programming-Language/phobos
https://github.com/D-Programming-Language/phobos/commit/492ab0df906d72a371a6ed950ee7b13ee4093047
Fix Issue 14149 - Bad std.algorithm error messages
https://github.com/D-Programming-Language/phobos/commit/685c27b2d8659bd6552fa5fba315dcff9ea69114
Merge pull request #2979 from sinkuu/fix_14149 Issue 14149 - Bad std.algorithm error messages
Comment #2
by sinkuupump — 2015-02-16T00:12:46Z
I forgot removing "Fix" from the commit message. Now it prints dirrerent errors: phobos/std/traits.d(516): Error: forward reference of variable parentPrefix phobos/std/traits.d(427): Error: template instance std.traits.fqnSym!(binaryFun) error instantiating phobos/std/algorithm/iteration.d(2487): instantiated from here: fullyQualifiedName!(binaryFun) phobos/std/algorithm/iteration.d(2471): instantiated from here: reduceImpl!(false, int[], string) phobos/std/algorithm/iteration.d(2455): instantiated from here: reducePreImpl!(int[], string) test.d(5): instantiated from here: reduce!(string, int[]) phobos/std/algorithm/iteration.d(2486): Error: static assert __error phobos/std/algorithm/iteration.d(2471): instantiated from here: reduceImpl!(false, int[], string) phobos/std/algorithm/iteration.d(2455): instantiated from here: reducePreImpl!(int[], string) test.d(5): instantiated from here: reduce!(string, int[]) This seems caused by Issue 13372. (fqnSym!(T) instantiates fqnSym!(__traits(parent, T)))
Comment #3
by github-bugzilla — 2015-02-18T03:42:10Z
Commits pushed to 2.067 at
https://github.com/D-Programming-Language/phobos
https://github.com/D-Programming-Language/phobos/commit/492ab0df906d72a371a6ed950ee7b13ee4093047
Fix Issue 14149 - Bad std.algorithm error messages
https://github.com/D-Programming-Language/phobos/commit/685c27b2d8659bd6552fa5fba315dcff9ea69114
Merge pull request #2979 from sinkuu/fix_14149
Comment #4
by github-bugzilla — 2015-02-21T09:17:53Z
Commits pushed to
https://github.com/D-Programming-Language/phobos
https://github.com/D-Programming-Language/phobos/commit/492ab0df906d72a371a6ed950ee7b13ee4093047
Fix Issue 14149 - Bad std.algorithm error messages
https://github.com/D-Programming-Language/phobos/commit/685c27b2d8659bd6552fa5fba315dcff9ea69114
Merge pull request #2979 from sinkuu/fix_14149
Comment #5
by n8sh.secondary — 2018-10-16T19:50:54Z
Current error message is: /dlang/dmd/linux/bin64/../../src/phobos/std/functional.d-mixin-215(215): Error: incompatible types for (__a) + (__b): string and int /dlang/dmd/linux/bin64/../../src/phobos/std/algorithm/iteration.d(3383): Error: template instance `std.functional.F!("a+b", "a", "b").binaryFun!(string, int)` error instantiating /dlang/dmd/linux/bin64/../../src/phobos/std/algorithm/iteration.d(3347): instantiated from here: reduceImpl!(false, int[], string) /dlang/dmd/linux/bin64/../../src/phobos/std/algorithm/iteration.d(3331): instantiated from here: reducePreImpl!(int[], string) onlineapp.d(5): instantiated from here: reduce!(string, int[])