[libsigcplusplus/variadic_mem_fun2] mem_fun.h.m4: Remove bound_const_mem_functor alias.
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libsigcplusplus/variadic_mem_fun2] mem_fun.h.m4: Remove bound_const_mem_functor alias.
- Date: Sun, 6 Mar 2016 20:16:29 +0000 (UTC)
commit b5298ac7a14f96a1888859d6d8d49f6f06928bb8
Author: Murray Cumming <murrayc murrayc com>
Date: Sun Mar 6 21:03:16 2016 +0100
mem_fun.h.m4: Remove bound_const_mem_functor alias.
It was only used in one place in the code and didn't add much clarity.
sigc++/functors/macros/mem_fun.h.m4 | 25 -------------------------
sigc++/signal.h | 6 +++++-
2 files changed, 5 insertions(+), 26 deletions(-)
---
diff --git a/sigc++/functors/macros/mem_fun.h.m4 b/sigc++/functors/macros/mem_fun.h.m4
index 899c655..523a1d8 100644
--- a/sigc++/functors/macros/mem_fun.h.m4
+++ b/sigc++/functors/macros/mem_fun.h.m4
@@ -36,25 +36,6 @@ using [$1]mem_functor =
T_arg...>;
])
-define([BOUND_MEMBER_FUNCTOR],[dnl
-
-/** bound_[$1]mem_functor encapsulates a $2 method with arguments and an object instance.
- * Use the convenience function mem_fun() to create an instance of bound_[$1]mem_functor.
- *
- * The following template arguments are used:
- * - @e T_arg... Argument type used in the definition of operator()().
- * - @e T_return The return type of operator()().
- * - @e T_obj The object type.
- *
- * @ingroup mem_fun
- */
-template<class T_return, class T_obj, class... T_arg>
-using bound_[$1]mem_functor =
- bound_mem_functor_base<
- T_return (T_obj::*)(T_arg...) $2,
- T_arg...>;
-])
-
define([MEM_FUN],[dnl
/** Creates a functor of type sigc::[$1]mem_functor which wraps a $3 method.
* @param _A_func Pointer to method that should be wrapped.
@@ -279,12 +260,6 @@ struct visitor<bound_mem_functor_base<T_func, T_arg...> >
#endif // DOXYGEN_SHOULD_SKIP_THIS
-//bound_const_mem_functor is just a convenience aliases used in the
-//definition of make_slot(). TODO: Remove it?
-
-BOUND_MEMBER_FUNCTOR([const_],[const])
-
-
MEM_FUN([],[],[])
MEM_FUN([const_],[const],[const])
MEM_FUN([volatile_],[],[volatile])
diff --git a/sigc++/signal.h b/sigc++/signal.h
index be7787e..307d2c1 100644
--- a/sigc++/signal.h
+++ b/sigc++/signal.h
@@ -922,7 +922,11 @@ public:
* @return A functor that calls emit() on this signal.
*/
decltype(auto) make_slot() const
- { return bound_const_mem_functor<result_type, signal_with_accumulator,
type_trait_take_t<T_arg>...>(*this, &signal_with_accumulator::emit); }
+ {
+ return bound_mem_functor_base<
+ result_type (signal_with_accumulator::*)(type_trait_take_t<T_arg>...) const,
+ type_trait_take_t<T_arg>...>(*this, &signal_with_accumulator::emit);
+ }
/** Creates an STL-style interface for the signal's list of slots.
* This interface supports iteration, insertion and removal of slots.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]