Updating generation to skip closure creation when last_was_func.

This greatly decreases running time for situations when the last_was_func
optimization held. However, it is no longer encapsulated in the priv_queue
module.