ELC in dev
ELC-lang
载入中...
搜索中...
未找到
elc::defs::base::invoke_t< T > 模板结构体 参考

struct  with_return_type_t
 

Public 成员函数

template<class... Args>
requires able<Args...>
decltype(auto_as (Args &&...rest) const noexcept(nothrow< Args... >)
 

静态 Public 属性

template<class... Args>
static constexpr bool able = ::std::is_invocable_v<T,Args...>
 
template<class... Args>
static constexpr bool nothrow = ::std::is_nothrow_invocable_v<T,Args...>
 
template<class Ret_t >
static constexpr with_return_type_t< Ret_twith_return_type {}
 

详细描述

template<typename T>
struct elc::defs::base::invoke_t< T >

在文件 all_defs.cpp12531 行定义.

成员函数说明

◆ _as()

template<typename T >
template<class... Args>
requires able<Args...>
decltype(auto) elc::defs::base::invoke_t< T >::_as ( Args &&...  rest) const
inlinenoexcept

A function that returns a λ that applies a function to a value.

参数
restThe arguments to the function.
返回
A λ that applies the function to a value.

在文件 all_defs.cpp12584 行定义.

12584 {//invoke<T>._as(...)
12585 return λ_with_catch(rest...)(const T&a)noexcept(nothrow<Args...>){return a(forward<Args>(rest)...);};
12586 }
#define λ_with_catch(...)
Definition all_defs.cpp:627
constexpr T down_cast(U a) noexcept
向下转型至

类成员变量说明

◆ able

template<typename T >
template<class... Args>
constexpr bool elc::defs::base::invoke_t< T >::able = ::std::is_invocable_v<T,Args...>
staticconstexpr

Determines if a type is invocable.

模板参数
TThe type to check.
ArgsThe types of the arguments to the type.
返回
True if the type is invocable, false otherwise.

在文件 all_defs.cpp12541 行定义.

◆ nothrow

template<typename T >
template<class... Args>
constexpr bool elc::defs::base::invoke_t< T >::nothrow = ::std::is_nothrow_invocable_v<T,Args...>
staticconstexpr

Determines if a type is invocable and nothrow.

模板参数
TThe type to check.
ArgsThe types of the arguments to the type.
返回
True if the type is nothrow invocable, false otherwise.

在文件 all_defs.cpp12551 行定义.

◆ with_return_type

template<typename T >
template<class Ret_t >
constexpr with_return_type_t<Ret_t> elc::defs::base::invoke_t< T >::with_return_type {}
staticconstexpr

在文件 all_defs.cpp12574 行定义.

12574{};

该结构体的文档由以下文件生成: