11#if !defined(__cpp_lib_char8_t)
15 char8_t(
char value) : value_(value) {}
16 char8_t(
const char8_t&) =
default;
17 char8_t(
char8_t&&) =
default;
19 operator char()
const {
return value_;}
20 bool operator==(
char8_t c)
const {
return value_ ==
c.value_;}
21 bool operator!=(
char8_t c)
const {
return value_ !=
c.value_;}
22 bool operator<(
char8_t c)
const {
return value_ <
c.value_;}
23 bool operator>(
char8_t c)
const {
return value_ >
c.value_;}
24 bool operator<=(
char8_t c)
const {
return value_ <=
c.value_;}
25 bool operator>=(
char8_t c)
const {
return value_ >=
c.value_;}
27 char8_t operator+(
char8_t c)
const {
return char8_t(value_ +
c.value_);}
28 char8_t operator-(
char8_t c)
const {
return char8_t(value_ -
c.value_);}
29 char8_t& operator=(
char8_t c) {value_ =
c.value_;
return *
this;}
30 char8_t& operator++() {value_ += 1;
return *
this;}
31 char8_t operator++(
int) {
char8_t result(*
this); ++(*this);
return result;}
32 char8_t& operator--() {value_ -= 1;
return *
this;}
33 char8_t operator--(
int) {
char8_t result(*
this); --(*this);
return result;}
35 bool operator==(
char c)
const {
return value_ ==
c;}
36 bool operator!=(
char c)
const {
return value_ !=
c;}
37 bool operator<(
char c)
const {
return value_ <
c;}
38 bool operator>(
char c)
const {
return value_ >
c;}
39 bool operator<=(
char c)
const {
return value_ <=
c;}
40 bool operator>=(
char c)
const {
return value_ >=
c;}
42 friend std::ostream& operator <<(std::ostream& os,
const char8_t& c)
noexcept {
return os << std::to_string(static_cast<int32_t>(
c.value_));}
49 using u8string=basic_string<char8_t>;
57 using byte_t = uint8_t;
59 using decimal_t =
long double;
60 using sbyte_t = int8_t;
61 using single_t = float;
62 using uchar_t =
unsigned char;
63 using ushort_t =
unsigned short;
64 using ulong_t =
unsigned long;
66#if defined(__linux__) && defined(_LP64)
67 using llong_t =
long long int;
68 using ullong_t =
unsigned long long int;
71 using ullong_t =
unsigned long;
Contains core_export_ keyword.
#define core_export_
Define shared library export.
Definition core_export.h:13
int16_t int16
Represents a 16-bit signed integer.
Definition types.h:121
char8_t char8
Represents a 16-bit unicode character.
Definition types.h:89
wchar_t wchar
Represents a wide character.
Definition types.h:251
decimal_t decimal
Represents a decimal-precision floating-point number.
Definition types.h:113
int32_t int32
Represents a 32-bit signed integer.
Definition types.h:129
unsigned char uchar
Represents a 8-bit unsigned integer.
Definition types.h:187
int64_t int64
Represents a 64-bit signed integer.
Definition types.h:137
int8_t sbyte
Represents a 8-bit signed integer.
Definition types.h:163
char16_t char16
Represents a 8-bit unicode character.
Definition types.h:97
uint32_t uint32
Represents a 32-bit unsigned integer.
Definition types.h:211
uintptr_t uintptr
Represent a pointer or a handle.
Definition types.h:227
std::nullptr_t null
Represents a null pointer value.
unsigned int uint
Represents a 32-bit unsigned integer.
Definition types.h:195
size_t size
Represents a size of any object in bytes.
Definition types.h:171
char32_t char32
Represents a 32-bit unicode character.
Definition types.h:105
intptr_t intptr
Represent a pointer or a handle.
Definition types.h:141
ushort_t ushort
Represents a 16-bit unsigned integer.
Definition types.h:235
ulong_t ulong
Represents a 32-bit or 64-bit unsigned integer.
Definition types.h:243
uint64_t uint64
Represents a 64-bit unsigned integer.
Definition types.h:219
uint8_t byte
Represents a 8-bit unsigned integer.
Definition types.h:81
uint16_t uint16
Represents a 16-bit unsigned integer.
Definition types.h:203
std::type_info type
Stores information about a type.
Definition types.h:179
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition system_report.h:17