support UFCS with fully qualified function names (was in "digitalmars.D.learn")

Timothee Cour thelastmammoth at gmail.com
Mon May 20 18:28:15 PDT 2013


(I've re-posting here upon request from bearophile, who seems to like it :)
)

I'd like to be able to use UFCS with fully qualified function names.

A typical use case is to disambiguate , as in the following case:

import std.path;
import std.string;
void main(){
    //Error: std.path.join()(const(char)[] p1, const(char)[] p2, const(char[
])[] more...) at ... conflicts with std.string.join at ...
    auto a="".join("\n");
    //what I'd like to have:
    auto a="".(std.path.join)("\n");
}

note: the fact that std.path.join!().join is deprecated is irrelevant to
this discussion.

Any chance this could be supported?

benefits:
avoids breaking UFCS chains
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20130520/d12232d7/attachment.html>


More information about the Digitalmars-d mailing list