Please feel free to provide feedback or file bugs here.

[Bug] Bitwise AND operation on long value is ignored when Most-Significant 32 bits is masked with zero

[Bug] Bitwise AND operation on long value is ignored when Most-Significant 32 bits is masked with zero

Sample Code to replicate issue:

[BitConverter]::GetBytes([BitConverter]::ToInt64(@(1,1,168,192,255,255,255,255), 0) -band 0x00000000ffffffff)

Should return: @(1,1,168,192,0,0,0,0)
Actually returns : @(1,1,168,192,255,255,255,255)

3 votes
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    I agree to the terms of service
    Signed in as (Sign out)

    We’ll send you updates on this idea

    Keith Geronimo Jackson shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    0 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)
      Submitting...

      Feedback and Knowledge Base