digitalmars.D.bugs - [Issue 19260] New: extern(C++) `T* const` mangling
- d-bugmail puremagic.com (25/25) Sep 22 2018 https://issues.dlang.org/show_bug.cgi?id=19260
https://issues.dlang.org/show_bug.cgi?id=19260 Issue ID: 19260 Summary: extern(C++) `T* const` mangling Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1 Component: dmd Assignee: nobody puremagic.com Reporter: turkeyman gmail.com This function: void deallocate(T* const ptr, size_t count); Is critical for linking STL, but I can't mangle the function. D should obviously declare the function as: void deallocate(T* ptr, size_t count); Which is semantically identical in terms of usage, but the mangling of the const pointer is different and therefore can't link. What can we do? I can't use pragma(mangle), because `T` is a template arg, and could be anything! This has stopped me in my tracks :/ --
Sep 22 2018