#pragma once typedef unsigned short size_t; typedef int ssize_t; typedef unsigned char uint8_t; constexpr uint8_t uint8_t_min = 0; constexpr uint8_t uint8_t_max = 0xff; typedef unsigned short uint16_t; constexpr uint16_t uint16_t_min = 0; constexpr uint16_t uint16_t_max = 0xffff; typedef unsigned int uint32_t; constexpr uint32_t uint32_t_min = 0; constexpr uint32_t uint32_t_max = 0xffffffff; typedef unsigned long long uint64_t; constexpr uint64_t uint64_t_min = 0; constexpr uint64_t uint64_t_max = 0xffffffffffffffff; typedef char int8_t; constexpr int8_t int8_t_max = uint8_t_max / 2; constexpr int8_t int8_t_min = -int8_t_max - 1; typedef short int16_t; constexpr int16_t int16_t_max = uint16_t_max / 2; constexpr int16_t int16_t_min = -int16_t_max - 1; typedef int int32_t; constexpr int32_t int32_t_max = uint32_t_max / 2; constexpr int32_t int32_t_min = -int32_t_max - 1; typedef long long int int64_t; constexpr int64_t int64_t_max = uint64_t_max / 2; constexpr int64_t int64_t_min = -int64_t_max - 1; /* Type Traits */ template struct integral_constant { constexpr T operator()() const { return v; } constexpr operator T() const { return v; } static const T value = v; }; /* is_same */ template struct is_same : integral_constant {}; template struct is_same : integral_constant {}; /* is_unsigned */ template struct is_unsigned : integral_constant(-1))> {}; /* error enum concept */ template concept error_enum_t = (__is_enum(T) && requires { T::NoError; });