Remove complex and imaginary types?
Christopher Wright
dhasenan at gmail.com
Tue Jan 8 17:21:10 PST 2008
Jason House wrote:
> Walter Bright Wrote:
>> I do too. And been thinking along the lines of simply putting a hack in
>> that the postfix 'i' means that it's a literal of type 'imaginary', and
>> the compiler looks to see if "std.complex" was imported.
>>
>> This isn't as outlandish as it sounds, as there's precedent for it both
>> in C++ <typeinfo> and java.lang.String, as well as D's Object.
>
> Any time a hack is needed, it's probably not the best solution. Somewhere in this thread, people talked about a generic interface for postfix labels. Examples given were i, ft, km. I'd be really cool to see something like that make its way into the language instead of a hack.
I'd rather it were not. It reduces clarity, since the postfixes will be
short and there will be a lot of collisions and it won't be clear where
they are defined.
More information about the Digitalmars-d
mailing list