You must wait for your mouth to get regular, free from the numbness of the anesthesia. It's important because you may bite the inside of your cheek, tongue, or lip if your mouth is numb. Also, the general rule of thumb is to eat only soft foods, as mentioned in this post, for the first 24-48 hours of the intervention. But it's best to ask your dentist for dietary instructions.