Change the signal/callback  API

Add the TYPEOF macro