Namespaces
Variants

std::meta::is_concept

From cppreference.com
< cpp | meta
 
 
 
Reflection library
 
Reflection types and queries
Type properties
Type property queries
 
Defined in header <meta>
consteval bool is_concept( std::meta::info r );
(since C++26)

Returns true if r represents a concept. Otherwise returns false.

Parameters

r - a reflection value

Return value

true if r represents a concept; otherwise false.

Example

#include <meta>
#include <type_traits>

// concept is a template
template<class T, class U>
concept Derived = std::is_base_of<U, T>::value;
static_assert(std::meta::is_template(^^Derived));

int main() {}

See also

checks if reflected entity is a template
(function) [edit]
obtains the template arguments of the reflected entity
(function) [edit]