Most of the time people won't need to set a cleanup callback, so we can simplify the more commonly used API.