Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Is it possible to right shift a signed variable? (12.7)
#3
The first two paragraphs of the answer given by Steve Montgomery have given a good summary of why shifting on signed integers can give problems.

Any shift on a signed integer will violate rule 12.7, because of the implementation defined behaviour of such shifts.
Posted by and on behalf of the MISRA C Working Group
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)