A version of curry that uses  a dispatcher to speed things up.