// // gapbind14 // Copyright (C) 2020-2022 James D. Mitchell // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by // the Free Software Foundation, either version 3 of the License, or // (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program. If not, see <https://www.gnu.org/licenses/>. //
#include <cstddef> // for size_t #include <functional> // for function #include <tuple> // for tuple, tuple_element_t #include <type_traits> // for true_type
template <typename C, typename R, typename... A> struct remove_class<R (C::*)(A...)> { using type = R(A...);
};
template <typename C, typename R, typename... A> struct remove_class<R (C::*)(A...) const> { using type = R(A...);
};
template <typename F> struct strip_function_object { using type = typename remove_class<decltype(&F::operator())>::type;
};
//////////////////////////////////////////////////////////////////////// // Function return type and parameter type info ////////////////////////////////////////////////////////////////////////
// For parameter packs . . . template <typename... TArgs> structPack { template <size_t i> using get = std::tuple_element_t<i, std::tuple<TArgs...>>;
};
template <typename TReturnType, typename... TArgs> struct CppFunctionBase { using arg_count = std::integral_constant<unsigned, sizeof...(TArgs)>; using return_type = TReturnType; using params_type = Pack<TArgs...>;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.