Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Bit shift bug. (*solved*)
#1
Bit shift by 0, when 0 is from a variable=0, which is incorrect!


Code:
DIM num as uByte=1
DIM num2 as uByte=0

PRINT num
PRINT (num<<0)
PRINT (num<<num2)

All three lines should read "1"
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)