? memfuntrackable.patch
? stamp-h1
? trackable.patch
? two_pointers.patch
? docs/manual/html
? tests/test_bind_ref
? tests/test_custom
Index: sigc++/functors/macros/mem_fun.h.m4
===================================================================
RCS file: /cvs/gnome/libsigc++2/sigc++/functors/macros/mem_fun.h.m4,v
retrieving revision 1.9
diff -u -p -r1.9 mem_fun.h.m4
--- sigc++/functors/macros/mem_fun.h.m4	1 Feb 2005 11:02:21 -0000	1.9
+++ sigc++/functors/macros/mem_fun.h.m4	27 Apr 2005 14:26:11 -0000
@@ -93,14 +93,14 @@ public:
    * @param _A_func Pointer to method will be invoked from operator()().
    */
   bound_[$2]mem_functor$1($3 T_obj* _A_obj, function_type _A_func)
-    : base_type_(_A_func), obj_ptr_(_A_obj) {}
+    : base_type_(_A_func), obj_ptr_derived_(_A_obj), obj_ptr_(_A_obj) {}
 
   /** Constructs a bound_[$2]mem_functor$1 object that wraps the passed method.
    * @param _A_obj Reference to instance the method will operate on.
    * @param _A_func Pointer to method will be invoked from operator()().
    */
   bound_[$2]mem_functor$1($3 T_obj& _A_obj, function_type _A_func)
-    : base_type_(_A_func), obj_ptr_(&_A_obj) {}
+    : base_type_(_A_func), obj_ptr_derived_(&_A_obj), obj_ptr_(&_A_obj) {}
 
   /** Execute the wrapped method operating on the stored instance.dnl
 FOR(1, $1,[
@@ -108,11 +108,14 @@ FOR(1, $1,[
    * @return The return value of the method invocation.
    */
   T_return operator()(LOOP(typename type_trait<T_arg%1>::take _A_a%1, $1)) const
-    { return (obj_ptr_->*(this->func_ptr_))(LOOP(_A_a%1, $1)); }
+    { return ( (obj_ptr_derived_)->*(this->func_ptr_))(LOOP(_A_a%1, $1)); }
+//    { return ( (($3 T_obj*)(obj_ptr_) )->*(this->func_ptr_))(LOOP(_A_a%1, $1)); }
 
 //protected:
   /// Pointer to stored object instance.
-  $3 T_obj *obj_ptr_;
+  // This is the handler object, such as TheObject in void TheObject::signal_handler().
+  $3 T_obj *obj_ptr_derived_;
+  $3 sigc::trackable* obj_ptr_;
 };
 
 //template specialization of visit_each<>(action, functor):
@@ -180,6 +183,7 @@ divert(0)
 __FIREWALL__
 #include <sigc++/type_traits.h>
 #include <sigc++/functors/functor_trait.h>
+#include <sigc++/trackable.h>
 
 namespace sigc {
 
Index: tests/test_compatibility.cc
===================================================================
RCS file: /cvs/gnome/libsigc++2/tests/test_compatibility.cc,v
retrieving revision 1.4
diff -u -p -r1.4 test_compatibility.cc
--- tests/test_compatibility.cc	19 Jan 2005 18:23:38 -0000	1.4
+++ tests/test_compatibility.cc	27 Apr 2005 14:26:11 -0000
@@ -22,7 +22,7 @@ SIGC_USING_STD(string)
 void print(const std::string &str)
   { std::cout << "print(str="<<str<<")" << std::endl; }
 
-struct blah
+struct blah : public SigC::Object
 {
   int test_int_int(int i)
     { std::cout << "blah::test_int_int(i="<<i<<")" << std::endl; return i*5; }
Index: tests/test_mem_fun.cc
===================================================================
RCS file: /cvs/gnome/libsigc++2/tests/test_mem_fun.cc,v
retrieving revision 1.7
diff -u -p -r1.7 test_mem_fun.cc
--- tests/test_mem_fun.cc	21 Jan 2005 12:40:53 -0000	1.7
+++ tests/test_mem_fun.cc	27 Apr 2005 14:26:11 -0000
@@ -10,7 +10,7 @@
 SIGC_USING_STD(cout)
 SIGC_USING_STD(endl)
 
-struct test
+struct test : sigc::trackable
 {
 void foo(short i1)
   {std::cout << "const test::foo(short "<< i1<< ')' <<std::endl; }
