Well, I would deliver the baby and if s/he was basically going to live a life attached to machines and unable to communicate or move then I would have the life support machines turned off. That would be no kind of a life. It would break my heart to do so though. However, to change the scenario a little bit, if I was late term and was told that my baby would basically be born a vegetable, I think I would continue the pregnancy and give the baby a chance. Doctors can be wrong. If they turned out to be correct, however, I would have life support removed.
I don't know, perhaps that is selfish of me though and it would be far kinder to have my baby 'put to sleep' in my womb and not have to suffer.
I may react very differently if, god forbid, I am ever faced with that situation.