dchar literals?

bearophile bearophileHUGS at lycos.com
Tue Nov 12 01:44:33 PST 2013


Kenji Hara:

> Or, uniform construction for built-in types would be another 
> better way.
>
> auto c = char('a');
> auto w = wchar('a');
> auto d = dchar('a');
>
> auto x = char('à');   // compile-time error

Yes, uniform construction syntax for all types seems a good idea. 
But the suffixes for chars, as the strings, could be a good idea 
any way, it's shorter, and it's symmetric with strings.

Bye,
bearophile


More information about the Digitalmars-d-learn mailing list