diff options
author | Laurent Bercot <ska-skaware@skarnet.org> | 2022-06-01 12:36:34 +0000 |
---|---|---|
committer | Laurent Bercot <ska@appnovation.com> | 2022-06-01 12:36:34 +0000 |
commit | e88276fdec7b3b94ec939f5eb1c8def004ee3878 (patch) | |
tree | 118f28d54fe208fe823e5e4cc775bbf377ea53a4 /src/headers/bits-bendian | |
parent | 37b42c179bb00d05cb47c739cb95283548f84fb2 (diff) | |
download | skalibs-e88276fdec7b3b94ec939f5eb1c8def004ee3878.tar.xz |
Rework endianness conversion primitives
Signed-off-by: Laurent Bercot <ska@appnovation.com>
Diffstat (limited to 'src/headers/bits-bendian')
-rw-r--r-- | src/headers/bits-bendian | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/headers/bits-bendian b/src/headers/bits-bendian index 6caf1e7..ac1169f 100644 --- a/src/headers/bits-bendian +++ b/src/headers/bits-bendian @@ -1,6 +1,8 @@ -#define uint@BITS@_little_endian(s, n) uint@BITS@_reverse((s), (n)) -#define uint@BITS@_big_endian(s, n) - #define uint@BITS@_little(u) uint@BITS@_bswap(u) #define uint@BITS@_big(u) (u) +#define uint@BITS@_littlep(u) uint@BITS@_bswapp(u) +#define uint@BITS@_bigp(u) + +#define uint@BITS@_littlen(array, n) uint@BITS@_bswapn(array, n) +#define uint@BITS@_bign(array, n) |