When I compiled the follwing code snippet, it compiled without any error.
My question is if it is allowed to declare char fields inside a structure, then how can I store character string in that variable(we can not use functoins like strcpy:-| ).
OR
Is it not allowed to declare char inside?
#include <stdio.h>
#include <string.h>
int main() {
struct aaa {
unsigned int a : 4;
unsigned char b : 24;
unsigned int c : 4;
};
struct aaa *pqr;
}
Thanks