X-Git-Url: https://git.distorted.org.uk/~mdw/catacomb-perl/blobdiff_plain/ef3af890207c78e8352e850ed9fd510c10f7db56..f9952aec1cf6c64a5681308eea817b6113a37433:/mp.xs diff --git a/mp.xs b/mp.xs index 5d78908..28c22f9 100644 --- a/mp.xs +++ b/mp.xs @@ -176,7 +176,7 @@ binop(a, b) XSINTERFACE_FUNC XSINTERFACE_FUNC_SETMP INTERFACE: - add sub mul and or xor + add sub mul and2c or2c nand2c nor2c xor2c and or nand nor xor mp * shiftop(a, n) @@ -188,7 +188,29 @@ shiftop(a, n) XSINTERFACE_FUNC XSINTERFACE_FUNC_SETMP INTERFACE: - lsl lsr + lsl lsr lsl2c lsr2c + +bool +testbitop(a, n) + mp *a + unsigned long n + INTERFACE_MACRO: + XSINTERFACE_FUNC + XSINTERFACE_FUNC_SETMP + INTERFACE: + testbit testbit2c + +mp * +flipbits(a, n) + mp *a + unsigned long n + C_ARGS: + MP_NEW, a, n + INTERFACE_MACRO: + XSINTERFACE_FUNC + XSINTERFACE_FUNC_SETMP + INTERFACE: + setbit clearbit setbit2c clearbit2c int mp_cmp(a, b)