Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- enum e1 {
- UNO = 1,
- DUE = 2,
- TRE = 3,
- QUATTRO = 4,
- } __attribute__((packed));
- enum e2 {
- UNOB = 1,
- DUEB = 2,
- TREB = 3,
- QUATTROB = 4,
- };
- int main(int argc, char *argv[])
- {
- enum e1 e1;
- enum e2 e2;
- printf("e1: %lu\n", sizeof(e1));
- printf("e2: %lu\n", sizeof(e2));
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement