2009-04-15から1日間の記事一覧

ビットシフトえらい!

というか、ビットフィールドって意外につかえないのね。 #include <stdio.h> typedef struct _bitf { unsigned int a:16; unsigned int b:8; unsigned int c:4; unsigned int d:2; unsigned int e:1; unsigned int f:1; } bitf; typedef struct _ubitf { union { bitf</stdio.h>…