Namespaces
Variants

std::meta::has_internal_linkage, std::meta::has_module_linkage, std::meta::has_external_linkage, std::meta::has_linkage

From cppreference.com
< cpp | meta
 
 
 
Reflection library
 
Reflection types and queries
Reflection queries
Reflection layout queries
Type properties
Type property queries
 
Defined in header <meta>
consteval bool has_internal_linkage( std::meta::info r );
(1) (since C++26)
consteval bool has_module_linkage( std::meta::info r );
(2) (since C++26)
consteval bool has_external_linkage( std::meta::info r );
(3) (since C++26)
consteval bool has_linkage( std::meta::info r );
(4) (since C++26)

Determines if r represents a variable, function, type, template, or namespace whose name has the specified linkage.

The result is true if and only if r represents an entity whose name has

1) internal linkage
2) module linkage
3) external linkage
4) any linkage

Parameters

r - a reflection value

Return value

true if r represents an entity whose name has the specified linkage; otherwise false.

Notes

If r does not represent an entity, the result is false.

Example

See also

checks if the reflected entity has "C" language linkage (extern "C")
(function) [edit]
Morty Proxy This is a proxified and sanitized view of the page, visit original site.