Cthulhu  0.2.10
Cthulhu compiler collection
endian.c File Reference
#include "endian/endian.h"
#include "base/panic.h"
Include dependency graph for endian.c:

Go to the source code of this file.

Functions

STA_DECL uint16_t endian_swap16 (uint16_t value)
 swap the endianess of a 16-bit value More...
 
STA_DECL uint32_t endian_swap32 (uint32_t value)
 swap the endianess of a 32-bit value More...
 
STA_DECL uint64_t endian_swap64 (uint64_t value)
 swap the endianess of a 64-bit value More...
 
STA_DECL uint16_t native_order16 (uint16_t value, endian_t order)
 convert a 16-bit value of a given endianess to the native endianess More...
 
STA_DECL uint32_t native_order32 (uint32_t value, endian_t order)
 convert a 32-bit value of a given endianess to the native endianess More...
 
STA_DECL uint64_t native_order64 (uint64_t value, endian_t order)
 convert a 64-bit value of a given endianess to the native endianess More...