http and lots of formats

This commit is contained in:
2026-01-05 00:30:37 +02:00
parent 965cecc901
commit f886350eb1
23 changed files with 1727 additions and 121 deletions

View File

@@ -54,6 +54,23 @@
#define POSIX
#endif
#define SWAP16(x) (uint16_t)((((x) >> 8) & 0x00FF) | \
(((x) << 8) & 0xFF00))
#define SWAP32(x) (uint32_t)((((x) >> 24) & 0x000000FF) | \
(((x) >> 8) & 0x0000FF00) | \
(((x) << 8) & 0x00FF0000) | \
(((x) << 24) & 0xFF000000))
#define SWAP64(x) ((uint64_t)( \
(((x) >> 56) & 0x00000000000000FFULL) | \
(((x) >> 40) & 0x000000000000FF00ULL) | \
(((x) >> 24) & 0x0000000000FF0000ULL) | \
(((x) >> 8) & 0x00000000FF000000ULL) | \
(((x) << 8) & 0x000000FF00000000ULL) | \
(((x) << 24) & 0x0000FF0000000000ULL) | \
(((x) << 40) & 0x00FF000000000000ULL) | \
(((x) << 56) & 0xFF00000000000000ULL) ))
#define abstract_class class