const challenge
Sean Kelly
sean at f4.ca
Sat Feb 2 11:25:57 PST 2008
Walter Bright wrote:
> Janice Caron wrote:
>> Still - nobody here was suggesting unique "on a whim". Rather, it was
>> to solve a class of problems, the most obvious of which is to allow
>> the following to compile:
>>
>> string s;
>> char[] t;
>> char[] u = "hello" ~ s ~ t;
>
> I understand that's a problem. The solution, however, doesn't need
> unique. It can be solved by having the result type of ~ be a polysemous
> type, i.e. its type is based on how it is used.
Awesome. I was wondering if that's where we were going with this.
Sean
More information about the Digitalmars-d
mailing list