Deprecate implicit `int` to `bool` conversion for integer literals

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Tue Nov 14 23:48:30 UTC 2017


On 11/14/2017 06:05 PM, Michael V. Franklin wrote:
> On Tuesday, 14 November 2017 at 13:54:03 UTC, Steven Schveighoffer wrote:
> 
>> IMO, no character types should implicitly convert from integer types. 
>> In fact, character types shouldn't convert from ANYTHING (even other 
>> character types). We have so many problems with this.
> 
> Is everyone in general agreement on this?  Can anyone think of a 
> compelling use case?

No, that would be too large a change of the rules. FWIW 'a' has type 
dchar, not char. -- Andrei



More information about the Digitalmars-d mailing list