From 60f60b28a92fdbf2139ff67a95bac996052d7c2b Mon Sep 17 00:00:00 2001 From: Laurent Bercot Date: Mon, 27 Nov 2017 15:13:33 +0000 Subject: Add _PACK and pack/unpack functions for signed types --- src/headers/signed-template | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/headers') diff --git a/src/headers/signed-template b/src/headers/signed-template index 2ef6fdd..b67b2bd 100644 --- a/src/headers/signed-template +++ b/src/headers/signed-template @@ -1,5 +1,10 @@ -#define @TYPE@_FMT (1+UINT@BITS@_FMT) +#define @TYPE@_PACK @BYTES@ +#define @type@_pack uint@BITS@_pack +#define @type@_pack_big uint@BITS@_pack_big +#define @type@_unpack uint@BITS@_unpack +#define @type@_unpack_big uint@BITS@_unpack_big +#define @TYPE@_FMT (1+UINT@BITS@_FMT) #define @type@_fmt int@BITS@_fmt #define @type@_fmtlist int@BITS@_fmtlist #define @type@_scan int@BITS@_scan -- cgit v1.2.3