How do I determine the order of a bitfield? I can change an element of a bitfield by doing x.c where x is a variable of the struct type. I have tried to bitmask it and print it out, but I can only print each element in the struct and not the entire variable. I have tried to assign a pointer to the elements of a bitfield but it comes up with an error. What is the best way to determine the order of a bitfield for a C compiler? For example which order would this struct be represented as?
struct bit_fields
{
unsigned int a : 6,
b : 8,
c : 18;
}