void bc_test() { int bits[BC_NBITS] = {0, 0, 0, 0, 0, 1, 0, 0}; assert(bc_bits2char(bits)==' '); assert(char2char(0)==0); assert(char2char(' ')==' '); }
void bc_test() { printf("bc_test\n"); int bits[BC_NBITS] = {0, 0, 0, 0, 0, 1, 0, 0}; printf("assert 1\n"); assert(bc_bits2char(bits)==' '); printf("assert 2\n"); assert(char2char(0)==0); printf("assert 3\n"); assert(char2char(' ')==' '); printf("assert end\n"); }
/* converts ch to itself via bits, for testing */ static int char2char(int ch) { int bits[BC_NBITS]; return bc_bits2char(bc_char2bits(ch, bits)); }
/* converts ch to itself via bits, for testing */ static int char2char(int ch) { printf("char2cahr\n"); int bits[BC_NBITS]; return bc_bits2char(bc_char2bits(ch, bits)); }