Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
C90: Bitfield as essential boolean type
#2
You would need to deviate from rule 6.1 if you wish to use an enumeration type as your essentially boolean type.

An alternative would be to define your bool_t as an unsigned int.
Code:
typedef unsigned int bool_t;
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)