On Friday, 22 December 2017 at 10:18:52 UTC, ketmar wrote:
crimaniak wrote:

Both operands are the same type, so as I understand casting to longest type is not needed at all, and longest type here is ushort in any case. What am I doing wrong?

it is hidden in specs: all types shorter than int are promoted to int before doing any math.

Hm, really. ok, I will use the explicit cast, but I don't like it.

Reply via email to