sparrow 1.0.0
Loading...
Searching...
No Matches
sparrow::mpl::constify< T, is_const > Struct Template Reference

Conditionally adds const to a type. More...

#include <mp_utils.hpp>

Public Types

using type = std::conditional_t<is_const, const T, T>
 

Detailed Description

template<typename T, bool is_const>
struct sparrow::mpl::constify< T, is_const >

Conditionally adds const to a type.

This utility allows conditional const-qualification based on a boolean template parameter, with special handling for reference types.

Template Parameters
TType to potentially const-qualify
is_constWhether to add const qualification

Definition at line 778 of file mp_utils.hpp.

Member Typedef Documentation

◆ type

template<typename T, bool is_const>
using sparrow::mpl::constify< T, is_const >::type = std::conditional_t<is_const, const T, T>

Definition at line 780 of file mp_utils.hpp.


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