Why does shifting right by a negative amount not shift left?
The Rust Programming Language Forum
Why does shifting right by a negative amount not shift left?
I'd expect 1u64 >> -1i32 to return 2, moving right by a negative distance is just moving left, but instead it panics. Playground: Rust Playground
0 comments
No comments yet.