digitalmars.D.learn - support UFCS with fully qualified function names
- Timothee Cour (16/16) May 20 2013 I'd like to be able to use UFCS with fully qualified function names.
- bearophile (9/12) May 20 2013 It seems an acceptably-looking syntax. But maybe D.learn is not
- bearophile (5/6) May 20 2013 I suggest to present it in the main D newsgroup. And if people
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
May 20 2013
Timothee Cour:I'd like to be able to use UFCS with fully qualified function names.auto a="".(std.path.join)("\n");It seems an acceptably-looking syntax. But maybe D.learn is not the best place to discuss new D syntax. Regarding new UFCS-related syntax, I sometimes wish for: alias T = foo.typeof; byBoolVal.assert; http://d.puremagic.com/issues/show_bug.cgi?id=4272 Bye, bearophile
May 20 2013
Timothee Cour:auto a="".(std.path.join)("\n");I suggest to present it in the main D newsgroup. And if people don't hate it, to later write an enhancement request in bugzilla. Bye, bearophile
May 20 2013