On 04/11/2014 02:00, Walter Bright wrote:
You are glossing over and dismissing the problems with explicit casts,
and the problems with overloading, etc.
Can't solving any overloading problem be deferred? An incomplete
solution is better than nothing.
As for explicit casts, they are easily avoided using std.conv:
uint u = unsigned(-1);
int i = signed(uint.max);
The compiler can recommend these instead of explicit casts.
Also, please note the pull request I linked tries hard using VRP to
avoid nagging the user with warnings/errors that it can detect are
unnecessary.
Given that Andrei pre-approved the design last April year*, it seems
surprising there's not yet been a solution.
* https://issues.dlang.org/show_bug.cgi?id=259#c35