Support callbacks that are not objects

Currently we only support objects with an __invoke method, which doesn't seem to be necessary.