> Wonder harder.
>
> If something is (& 3) it is also either (& 2 || & 1)
> so why have both below the first test?

I can interpret the source code example in the way that the number
of set bits are checked.
I can eventually become concerned around the preferred coding style
because of the usage of these constant values.
Would you like to check the use of bit fields?


>> * Where do you stumble on difficulties to express a corresponding source code
>>   search pattern by the means of the semantic patch language?
>
> #defines, shifts, masks

You come along the usual development challenges for the safe handling
of possible code variations.
With which approach would you like to start and perform further
source code analysis?

Regards,
Markus
_______________________________________________
Cocci mailing list
Cocci@systeme.lip6.fr
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to