header_utils
Loading...
Searching...
No Matches
Scope

RAII-related types. More...

Classes

struct  ghassanpl::scope_guard< EF >
 An RAII class that executes a function on destruction. More...
struct  ghassanpl::counted_scope_guard< EF >
 An RAII class that executes a function on destruction, if its request counter is greater than zero. More...
struct  ghassanpl::unique_resource< R, D >
 An equivalent to unique_ptr for values that are not heap pointers. More...
struct  ghassanpl::scoped_value_change< T, IS_OPTIONAL >
 An RAII class that changes the value of a variable and reverts it to the original value on destruction. More...
struct  ghassanpl::scope_counter< T >
 An RAII class that increments a value on construction and decrements it on destruction. More...

Typedefs

template<typename T>
using ghassanpl::optional_scoped_value_change

Functions

template<class EF>
 ghassanpl::scope_guard (EF) -> scope_guard< EF >
template<class R, class D>
 ghassanpl::unique_resource (R, D) -> unique_resource< R, D >
template<class R, class D, class I = std::decay_t<R>>
 ghassanpl::unique_resource (R, I, D) -> unique_resource< R, D >
template<typename T, typename U>
 ghassanpl::scoped_value_change (T &, U &&) -> scoped_value_change< T >

Detailed Description

RAII-related types.

Typedef Documentation

◆ optional_scoped_value_change

template<typename T>
using ghassanpl::optional_scoped_value_change

Definition at line 394 of file scope.h.