Melon
A C++ library designed for RadishOS.
Loading...
Searching...
No Matches
Typing.hpp
1
2#pragma once
3
4#include <stdint.h>
5#include <sys/types.h>
6#include <stddef.h>
7#include <ctype.h>
8
13{
15 using Int8 = int8_t;
17 using Int16 = int16_t;
19 using Int32 = int32_t;
21 using Int64 = int64_t;
23 using IntPointer = intptr_t;
25 using ISize = ssize_t;
26
28 using Uint8 = uint8_t;
30 using Uint16 = uint16_t;
32 using Uint32 = uint32_t;
34 using Uint64 = uint64_t;
36 using UPointer = uintptr_t;
38 using USize = size_t;
39
40 inline constexpr bool isSpace(char ch)
41 {
42 return isspace(ch);
43 }
44
45 inline constexpr bool isDigit(char ch)
46 {
47 return isdigit(ch);
48 }
49} // namespace Melon::Typing
Contains fixed-size types.
Definition Typing.hpp:13
int8_t Int8
Signed 8-bit integer.
Definition Typing.hpp:15
int64_t Int64
Signed 64-bit integer.
Definition Typing.hpp:21
size_t USize
Biggest unsigned type.
Definition Typing.hpp:38
ssize_t ISize
Biggest signed type.
Definition Typing.hpp:25
uint8_t Uint8
Unsigned 8-bit integer.
Definition Typing.hpp:28
uint32_t Uint32
Unsigned 32-bit integer.
Definition Typing.hpp:32
uintptr_t UPointer
Biggest unsigned pointer type.
Definition Typing.hpp:36
uint16_t Uint16
Unsigned 16-bit integer.
Definition Typing.hpp:30
uint64_t Uint64
Unsigned 64-bit integer.
Definition Typing.hpp:34
int16_t Int16
Signed 16-bit integer.
Definition Typing.hpp:17
intptr_t IntPointer
Biggest signed pointer type.
Definition Typing.hpp:23
int32_t Int32
Signed 32-bit integer.
Definition Typing.hpp:19