1 print("bit.signextend(0x85, 6)=" .. bit
.tohex(bit
.signextend(0x85, 6)));
2 print("bit.signextend(0x85, 7)=" .. bit
.tohex(bit
.signextend(0x85, 7)));
3 print("bit.signextend(0x85, 8)=" .. bit
.tohex(bit
.signextend(0x85, 8)));
4 print("bit.tosigned(0x85, 6)=" .. bit
.tosigned(0x85, 6));
5 print("bit.tosigned(0x85, 7)=" .. bit
.tosigned(0x85, 7));
6 print("bit.tosigned(0x85, 8)=" .. bit
.tosigned(0x85, 8));