Struct meta_function_descriptor< Type, Ret(Class::*)(Args...)>

Synopsis

#include <src/entt/meta/utility.hpp>

template<typename Type, typename Ret, typename Class, typename... Args>
struct meta_function_descriptor<Type, Ret(Class:: *)(Args...)>

Description

Meta function descriptor.

Template Parameters

Type - Reflected type to which the meta function is associated.

Ret - Function return type.

Class - Actual owner of the member function.

Args - Function arguments.

Source

Lines 52-63 in src/entt/meta/utility.hpp.

template<typename Type, typename Ret, typename Class, typename... Args>
struct meta_function_descriptor<Type, Ret(Class:: *)(Args...)> {
    /*! @brief Meta function return type. */
    using return_type = Ret;
    /*! @brief Meta function arguments. */
    using args_type = std::conditional_t<std::is_same_v<Type, Class>, type_list<Args...>, type_list<Class &, Args...>>;

    /*! @brief True if the meta function is const, false otherwise. */
    static constexpr auto is_const = false;
    /*! @brief True if the meta function is static, false otherwise. */
    static constexpr auto is_static = !std::is_same_v<Type, Class>;
};





Add Discussion

Log in to comment