1 /* Test first bit operations from stdbit.h
3 type: unsigned short, unsigned int, unsigned long, unsigned long long
8 #ifdef __SDCC // Todo: Enable for all C23 implementations
20 #ifdef __SDCC // Todo: Enable for all C23 implementations
22 ASSERT (stdc_first_trailing_one(i
) == 0);
23 ASSERT (stdc_first_trailing_zero(i
) == 1);
26 ASSERT (stdc_first_trailing_one(i
) == 1);
27 ASSERT (stdc_first_trailing_zero(i
) == 2);
30 ASSERT (stdc_first_trailing_one(i
) == 2);
31 ASSERT (stdc_first_trailing_zero(i
) == 1);
34 ASSERT (stdc_first_trailing_one(i
) == 1);
35 ASSERT (stdc_first_trailing_zero(i
) == 3);
38 ASSERT (stdc_first_trailing_one(i
) == 1);
39 ASSERT (stdc_first_trailing_zero(i
) == 4);
42 ASSERT (stdc_first_trailing_one(i
) == 4);
43 ASSERT (stdc_first_trailing_zero(i
) == 1);
46 ASSERT (stdc_first_trailing_one(i
) == 1);
47 ASSERT (stdc_first_trailing_zero(i
) == 2);