◐ Shell
reader mode source ↗
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 is_vararg_function( std::meta::info r );
(since C++26)

Returns true if r represents a vararg function. Otherwise returns false.

A vararg function (also known as variadic function) is a function whose parameter list ends with an ellipsis that is not a pack expansion. Such functions take a variable number of arguments.

Parameters

r - a reflection value

Return value

true if r represents a vararg function; otherwise false.

Example

#include <meta>

void f(...);
static_assert(std::meta::is_vararg_function(^^f));

void g(auto...);
static_assert(!std::meta::is_vararg_function(^^g));

int main() {}

See also

checks if reflection represents a function
(function) [edit]