libyggdrasil  v1.0.0
types.hpp File Reference

Commonly used type definitions and helper templates. More...

#include <cstdint>
Include dependency graph for types.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  bsp::TypeSafe< T >
 Helper class to create type-safe integral types. More...
 

Namespaces

 bsp
 

Macros

#define TYPESAFE(T)   struct : public ::bsp::TypeSafe<int>{ using TypeSafe::TypeSafe; }
 Creates a new, type-safe integral type. More...
 

Typedefs

template<typename T >
using bsp::IO = volatile T
 MMIO type template. More...
 
using u8 = std::uint8_t
 Unsigned integer definitions. More...
 
using u16 = std::uint16_t
 
using u32 = std::uint32_t
 
using u64 = std::uint64_t
 
using i8 = std::int8_t
 Signed integer definitions. More...
 
using i16 = std::int16_t
 
using i32 = std::int32_t
 
using i64 = std::int64_t
 
using bsp::addr_t = std::uint32_t
 ARM32 specific types. More...
 
using bsp::reg_t = std::uint32_t
 
constexpr auto bsp::RegisterAlignment = alignof(reg_t)
 ARM32 specific constants. More...
 

Detailed Description

Commonly used type definitions and helper templates.

Author
Fabian Weber, Nikolaij Saegesser

Macro Definition Documentation

◆ TYPESAFE

#define TYPESAFE (   T)    struct : public ::bsp::TypeSafe<int>{ using TypeSafe::TypeSafe; }

Creates a new, type-safe integral type.

Example use: using TypeSafeU16 = TYPESAFE(u16);

Parameters
TType

Typedef Documentation

◆ i16

using i16 = std::int16_t

◆ i32

using i32 = std::int32_t

◆ i64

using i64 = std::int64_t

◆ i8

using i8 = std::int8_t

Signed integer definitions.

◆ u16

using u16 = std::uint16_t

◆ u32

using u32 = std::uint32_t

◆ u64

using u64 = std::uint64_t

◆ u8

using u8 = std::uint8_t

Unsigned integer definitions.