A - Thanks for the questions. The Church has never changed her doctrine. But, we might have to define what doctrine is. Doctrine is a teaching of the Church that comes from or is necessarily connected to the deposit of faith the Church was given by Christ and from the Apostles.
What happened in the case of limbo is this - limbo was a theological supposition (a guess by some theologians) as to what happened to unbaptized babies when they died. The term was first derived from
- though he taught that unbaptized infants went to hell (though a hell not quite as bad as the rest). The picture at the right is one of my youngest daughter before she was baptized. In my humble opinion, this is one of the rare times that Augustine got it wrong. St. Augustine
The argument went something like this (note that I don't agree with what I am typing out here) - an unbaptized baby couldn't go to heaven because they weren't baptized. The Church does teach a baptism of desire - which is (in the words of Fr. John Hardon)
"Baptism of desire is the implicit desire for baptism of water by a person who makes an act of perfect love of God, based on faith and with a sincere sorrow for one's sins. Such was the case in the Acts of the Apostles, when Peter encountered pagans who, moved by the grace of the Holy Spirit, proclaimed the greatness of God. "Peter himself then said, 'Could anyone refuse the water of baptism to these people, now they have received the Holy Spirit....?'" (Acts 10:46-47)"
But, since a baby would not have a developed intellect to have known or chosen God, they couldn't be baptized by desire.
On the other hand, God wouldn't send them to hell because they never personally sinned. Therefore, there must be another place, limbo, as the alternative destiny. They would be happy, but never enter into the beatific vision (heaven).
Now, Catholics were, for many years, allowed to agree with limbo or not. Because this guess was allowed, as many other theological suppositions are in the gray areas. This is the freedom that the Church allows. But, because this belief hasn't been held consistently since the time of the apostles (who handed on Christ's revelation to the Church) and because of clearer statements made on the unbaptized in Vatican II and the Cathechism, the Vatican decided to make a statement about limbo that said it was not true. So, just because she made a statement that the guess of limbo was wrong, does not mean she changed anything - because the Church never taught it as being from Christ or the apostles (i.e., doctrine).
Pope Benedict, before he was Pope, told a reporter the following about limbo in an interview in his book "The Ratzinger Report":
"Limbo was never a defined truth of faith. Personally -- and here I am speaking more as a theologian and not as prefect of the congregation -- I would abandon it, since it was only a theological hypothesis."
Here is what the Catechism says now, leaving the question open still - but without limbo.
"As regards children who have died without Baptism, the Church can only entrust them to the mercy of God, as she does in her funeral rites for them. Indeed, the great mercy of God who desires that all men should be saved, and Jesus’ tenderness toward children which caused him to say: ‘Let the children come to me, do not hinder them,’ allow us to hope that there is a way of salvation for children who have died without Baptism. All the more urgent is the Church’s call not to prevent little children coming to Christ through the gift of holy Baptism” (No. 1261)
Then in 2007 a commission of theologians, which was originally put together by Pope John Paul II issued a statement on limbo. Their conclusion reads:
Our conclusion is that the many factors that we have considered above give serious theological and liturgical grounds for hope that unbaptized infants who die will be saved and enjoy the beatific vision. We emphasize that these are reasons for prayerful hope, rather than grounds for sure knowledge. There is much that simply has not been revealed to us. We live by faith and hope in the God of mercy and love who has been revealed to us in Christ, and the Spirit moves us to pray in constant thankfulness and joy.What has been revealed to us is that the ordinary way of salvation is by the sacrament of baptism. None of the above considerations should be taken as qualifying the necessity of baptism or justifying delay in administering the sacrament. Rather, as we want to reaffirm in conclusion, they provide strong grounds for hope that God will save infants when we have not been able to do for them what we would have wished to do, namely, to baptize them into the faith and life of the Church.
As for the question on infallibility. Not every Church teaching is taught infallibly. I wrote on this in another post that explains it.
I hope that helps.