MCPcopy Create free account
hub / github.com/ArashPartow/exprtk / base_func

Class base_func

exprtk_test.cpp:5858–5870  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5856
5857template <typename T>
5858struct base_func : public exprtk::ifunction<T>
5859{
5860 using exprtk::ifunction<T>::operator();
5861
5862 typedef const T& type;
5863 base_func(const std::size_t& n) : exprtk::ifunction<T>(n) {}
5864 inline T operator()(type v0, type v1, type v2, type v3, type v4) exprtk_test_override { return (v0 + v1 + v2 + v3 + v4); }
5865 inline T operator()(type v0, type v1, type v2, type v3) exprtk_test_override { return (v0 + v1 + v2 + v3); }
5866 inline T operator()(type v0, type v1, type v2) exprtk_test_override { return (v0 + v1 + v2); }
5867 inline T operator()(type v0, type v1) exprtk_test_override { return (v0 + v1); }
5868 inline T operator()(type v0) exprtk_test_override { return v0; }
5869 inline T operator()() exprtk_test_override { return T(1.1234); }
5870};
5871
5872template <typename T> struct test_func5 exprtk_test_final : public base_func<T> { test_func5() : base_func<T>(5){} };
5873template <typename T> struct test_func4 exprtk_test_final : public base_func<T> { test_func4() : base_func<T>(4){} };

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected