Namespaces | |
namespace | detail |
Classes | |
struct | AddMemberGet |
class | Badge |
class | DeferConstruct |
struct | GetInPlaceFunction |
class | GuardedReference |
struct | Immovable |
class | MovableBox |
class | NamedArgument |
A helper class to simulate a single named argument. More... | |
class | NamedArguments |
A helper class for simulation named arguments in c++. More... | |
struct | NonCopyable |
class | NonPropagatingCache |
struct | OwnedType |
class | RebindableBox |
class | ReferenceWrapper |
class | ScopeExit |
class | ScopeValueChange |
struct | SelfPointer |
class | SourceLocation |
struct | StoreIf |
struct | StoreIf< T, false > |
class | StrongInt |
struct | SwapFunction |
class | UUID |
Functions | |
template<typename T> | |
constexpr auto | as_const_pointer (T const *pointer) |
template<concepts::CopyConstructible T> | |
auto | black_box (T const &value) -> T |
template<auto... values> | |
void | compile_time_fail () |
constexpr void | compiler_barrier () |
Force to optimizer to reload memory addresses. | |
template<typename T, typename... Args> requires (concepts::LanguageVoid<T> || concepts::CreatableFrom<T, Args...>) | |
constexpr auto | create (Args &&... args) |
template<template< typename... > typename Template, typename... Args> requires (concepts::TemplateCreatableFrom<Template, Args...>) | |
constexpr auto | create (Args &&... args) |
template<typename T> | |
auto | declval () -> meta::AddRValueReference< T > |
template<typename T> | |
DeferConstruct (T) -> DeferConstruct< T > | |
template<typename T, typename U = T> | |
constexpr auto | exchange (T &object, U &&new_value) -> T |
template<typename Derived, typename Base> requires (concepts::DerivedFrom<meta::RemoveCVRef<Derived>, Base>) | |
constexpr auto | forward_as_base (meta::RemoveReference< Derived > &derived) -> meta::Like< meta::RemoveReference< Derived > &, Base > && |
template<typename Derived, typename Base> requires (concepts::DerivedFrom<meta::RemoveCVRef<Derived>, Base>) | |
constexpr auto | forward_as_base (meta::RemoveReference< Derived > &&derived) -> meta::Like< meta::RemoveReference< Derived > &&, Base > && |
template<typename T, typename U> | |
constexpr auto | forward_like (U &&value) -> decltype(auto) |
template<types::size_t index, typename T> | |
constexpr auto | get (T &&value) -> decltype(auto) |
constexpr auto | is_constant_evaluated () noexcept -> bool |
template<typename... Args> | |
NamedArguments (Args &&...) -> NamedArguments< Args &&... > | |
template<typename T> | |
RebindableBox (T &&) -> RebindableBox< meta::UnwrapRefDecay< T > > | |
template<typename T> | |
constexpr auto | make_rebindable_box (T &&value) |
template<typename T> | |
ReferenceWrapper (T &) -> ReferenceWrapper< T > | |
template<typename F> | |
ScopeExit (F) -> ScopeExit< F > | |
template<typename T> | |
ScopeValueChange (T &, T) -> ScopeValueChange< T > | |
void | unreachable () |
|
constexpr |
auto di::util::black_box | ( | T const & | value | ) | -> T |
void di::util::compile_time_fail | ( | ) |
|
constexpr |
Force to optimizer to reload memory addresses.
In certain cases, the compiler is able to cache the result of a read from a memory address. Inserting a compiler barrier will prevent this, and force the compiler to reload the value.
|
constexpr |
|
constexpr |
auto di::util::declval | ( | ) | -> meta::AddRValueReference<T> |
di::util::DeferConstruct | ( | T | ) | -> DeferConstruct< T > |
|
constexpr |
|
constexpr |
|
constexpr |
|
nodiscardconstexpr |
|
constexpr |
|
constexprnoexcept |
|
constexpr |
di::util::NamedArguments | ( | Args && | ... | ) | -> NamedArguments< Args &&... > |
di::util::RebindableBox | ( | T && | ) | -> RebindableBox< meta::UnwrapRefDecay< T > > |
di::util::ReferenceWrapper | ( | T & | ) | -> ReferenceWrapper< T > |
di::util::ScopeExit | ( | F | ) | -> ScopeExit< F > |
di::util::ScopeValueChange | ( | T & | , |
T | ) -> ScopeValueChange< T > |
|
inline |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
A helper function to access a named argument.
Arg | The type of the named argument. |
args | The named arguments to access. |
This function is used to access a named argument from a list of named arguments. Note that it is a compile-time error to call this function with a named argument that is not present in the list of named arguments. Therefore, the concepts::HasNamedArgument concept should be used with an if constexpr
block before calling this method. Otherwise, use the util::get_named_argument_or function.
|
inlineconstexpr |
A helper function to access a named argument or a fallback value.
Arg | The type of the named argument. |
args | The named arguments to access. |
fallback | The fallback value to use if the named argument is not present. |
This function is used to access a named argument from a list of named arguments. If the named argument is not present in the list of named arguments, the fallback value is returned instead. To prevent dangling references, the returned argument is decay copied out.
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
struct di::util::SwapFunction di::util::swap |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |