I am not seeing the problem from excluding a baby from teaching sessions to be considerate of other students in the lecture.
The baby does not have to be crying, he just needs to be awake to be a distraction e.g. if he is gurgling or making noises or intermittently fussing or the mother could be speaking to the baby to interact with him if he is awake - unlikely a mother can prevent herself from interacting with a baby who is awake and it's not fair on the baby if she does ignore him. He requires eye contact, stimulation and interaction if he is awake in order to thrive.
These days the university lectures and notes are available online so any student who is going to miss a lecture can easily catch-up.