On Monday, 11 November 2013 at 13:20:04 UTC, bearophile wrote:
Philippe Sigaud:

And I agree with you than character literals should default to dchar. It's
a perpetual source of friction for me.

99% of my char literals need to be of type char.

On the other hand once you have suffixes to specify the char type, most of that problem vanishes, because writing 'x'c or 'x'w, 'x'd is good.

Bye,
bearophile

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

Kenji Hara

Reply via email to