Closed rocallahan closed 4 months ago
This avoids issues due to some platforms making char signed and others unsigned. In particular, on platforms where char is unsigned, https://github.com/lsils/mockturtle/blob/50ffa108484ba65b44eee4a713832b7ee821d6d8/lib/bill/bill/sat/interface/abc_bsat2.hpp#L156 promotes an lbool to int and compares to -1 ... but promoting (unsigned char)-1 to int produces 255.
char
lbool
int
(unsigned char)-1
Verified correct behavior on experiments Thanks for catching the issue
This avoids issues due to some platforms making
char
signed and others unsigned. In particular, on platforms wherechar
is unsigned, https://github.com/lsils/mockturtle/blob/50ffa108484ba65b44eee4a713832b7ee821d6d8/lib/bill/bill/sat/interface/abc_bsat2.hpp#L156 promotes anlbool
toint
and compares to -1 ... but promoting(unsigned char)-1
toint
produces 255.