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

Walter Bright newshound2 at digitalmars.com
Wed Nov 15 04:24:58 UTC 2017


On 11/14/2017 5:20 AM, Nick Treleaven wrote:
> An very similar problem exists for int and char overloads:
> 
> alias foo = (char c) => 1;
> alias foo = (int i) => 4;
> 
> enum int e = 7;
> static assert(foo(e) == 4); // fails

I cannot reproduce this error.


More information about the Digitalmars-d mailing list