Redundancy in languages by Walter

Max Samukha maxsamukha at gmail.com
Mon Jun 1 20:21:33 UTC 2020


On Monday, 1 June 2020 at 06:53:05 UTC, Ali Çehreli wrote:

> Yes, implicit conversion is a concern but I didn't take the 
> point that way: When the type is not spelled out, it means 
> "whatever the type of the expression is." On the other hand, if 
> one uses 'int' e.g. because the type of the expression is 'int' 
> today, the compiler cannot know whether the programmer means 
> "whatever the type of the expression is" or "I want 
> specifically int". Note that 'int' conversion may not be lossy 
> or wrong at all; there may be a perfectly valid 'int' 
> conversion.
>
> The issue is, the compiler cannot know and that's why Walter 
> calls this a bad redundancy.
>
> Ali

It seems you can look at it this way as well.


More information about the Digitalmars-d mailing list