PROPOSAL: Fully-qualified names to extend overload sets
Russell Lewis
webmaster at villagersonline.com
Mon May 12 16:52:41 PDT 2008
Russell Lewis wrote:
> Likewise, when you *use* the symbol, you are accessing the entire
> overload set (including the add-ons). (NOTE: Since the original module
> doesn't know about any of its add-ons, you are only overloading using
> the things that you have defined using your imports. See example below.)
Let me restate this in a better way (I really struggled to explain it in
my original post):
The idea is that when you use an unqualified name, this name is mapped
by the compiler to some fully-qualified name (basically like current
overload sets work). We then calculate the set of possible overloads as
if the user had used the fully-qualified name.
Of course, just like the current overload sets design, if there is any
ambiguity, then the compiler produces an error.
More information about the Digitalmars-d
mailing list