Because someone could object that absolutely considered (simpliciter) it is better to exist even in tribulations than not to have been born at all, he rejects this opinion saying, "would that I had perished," in my mother's womb," so that no eye would see me," so as not to suffer shame from the great evils which the eyes of men contemplate in me. If I had perished in my mother's womb, I would still have had the dignity of existing without the unhappiness which befell me in existing. He speaks about this saying, "I would have been," i.e. I would have participated in what is good in existing, "a...s though I had not been," I would have been free from the evils of this life as though I had never existed. For the dignity of man's being does not consist in being preserved perpetually. But rather, at length, as man dies and is carried to a tomb which is prepared for the dead so that his memory may remain after death in some way. I would have been without even this, and so the text continues, "carried from womb to tomb."
Source: Commentary on Job