Skip to main content

_t Struct Template

Deprecated generic strongly-typed wrapper for explicit type conversion. More...

Declaration

template <class T> struct micro_os_plus::micro_test_plus::_t<T> { ... }

Included Headers

Base struct

structvalue<T, Opt>

Struct template representing a generic value, accessible via a getter. More...

Public Member Typedefs Index

template <class T>
usingvalue_type = T

The type of the encapsulated value. More...

Public Constructors Index

constexpr_t (const T &t)

Constructor for the deprecated strongly-typed wrapper. More...

Public Operators Index

template <class T>
constexproperator T () const

Explicit conversion operator to the underlying value type. More...

Public Member Functions Index

template <class T>
constexpr auto get (void) const -> decltype(auto)

Getter for the encapsulated value. More...

Public Member Attributes Index

template <class T>
Tvalue_ {}

The encapsulated value. More...

Description

Deprecated generic strongly-typed wrapper for explicit type conversion.

The _t template provides a public, strongly-typed wrapper for any type T, enabling explicit conversion of dynamic values and expressions to a type recognised by the µTest++ comparators and reporting mechanisms.

This wrapper inherits from type_traits::value<T>, ensuring that the encapsulated value is treated as the specified type within the framework.

Deprecated

Use to_t (since 3.2.0).

Definition at line 639 of file literals.h.

Public Member Typedefs

value_type

template <class T>
using micro_os_plus::micro_test_plus::type_traits::value< T, Opt >::value_type = T

The type of the encapsulated value.

Definition at line 974 of file type-traits.h.

974 using value_type = T;

Public Operators

operator T()

template <class T>
micro_os_plus::micro_test_plus::type_traits::value< T, Opt >::operator T ()
inline explicit nodiscard constexpr

Explicit conversion operator to the underlying value type.

Returns

The stored value as type T.

Allows explicit conversion to the encapsulated value.

Definition at line 994 of file type-traits.h.

994 operator T () const
995 {
996 return value_;
997 }

Public Member Functions

get()

template <class T>
decltype(auto) micro_os_plus::micro_test_plus::type_traits::value< T, Opt >::get (void)
inline nodiscard constexpr

Getter for the encapsulated value.

Parameters

None.

Returns

The value of type T.

Returns the stored value.

Definition at line 1010 of file type-traits.h.

1010 get (void) const
1011 {
1012 return value_;
1013 }

Public Member Attributes

value_

template <class T>
T micro_os_plus::micro_test_plus::type_traits::value< T, Opt >::value_ {}

The encapsulated value.

Definition at line 1018 of file type-traits.h.


The documentation for this struct was generated from the following file:


Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.14.0.