phobos's circle CI runs a busted version of DMD

deadalnix deadalnix at gmail.com
Wed Jan 11 17:27:16 UTC 2023


On Wednesday, 11 January 2023 at 13:26:57 UTC, Dukc wrote:
> [The spec 
> says](https://dlang.org/spec/expression.html#shift_expressions) 
> that `>>` means *signed* shift right. `>>>` is for unsigned 
> shifts. So pedantically speaking, 64516 is the correct result.
>
> It's another issue whether that's good design though. For one, 
> it breaks the rule "do what C does, or don't compile". It'd be 
> more reasonable if `>>` was type-dependant shift right (as in 
> C) IMO.

Signed right shift is the same as logical right shift for 
unsigned integrals.


More information about the Digitalmars-d mailing list