And who taught that the world was 6000 years old?
The Catholic Church? If so, please cite the document and the source.
The document is the bible (I assume you won’t need a link). It gives quite a reasonably accurate chronology.
Back to Leo XIII (same link as before):
“For all the books which the Church receives as sacred and canonical are written wholly and entirely, with all their parts, at the dictation of the Holy Spirit; and so far is it from being possible that any error can coexist with inspiration, that inspiration not only is essentially incompatible with error, but excludes and rejects it as absolutely and necessarily as it is impossible that God Himself, the supreme Truth, can utter that which is not true. This is the ancient and unchanging faith of the Church, solemnly defined in the Councils of Florence and Trent, and finally and more expressly formulated by the [First] Council of the Vatican.”
He’s already said that if science should arrive at different conclusions regarding factual matters within the bible, then science will trump scripture. In effect saying that if the bible is being used to teach people about (for example) the age of the earth, then it might not necessarily be true.
But above he is in no doubt that, until such time as that occurs, the bible, ‘wholly and entirely’ is without error. Very close to what the catechism says today. But taken together, the two quotes effectively state that: this must be accepted as being true, unless it is shown not to be so. Again, quite reasonable.
Now I will grant you you the Catholic Church has probably never explicitly stated that the world is 6,000 years old. But for many centuries, it taught that scripture was be be treated as being without error. Therefore, the chronology was without error. Therefore…the planet was a few thousand years old.
These days, the catechism, despite it saying pretty much what Leo said in that first paragraph, goes on to allow for a more liberal approach to interpreting scripture. That Catholicism is not a ‘religion of the book’. So hey, the science tells us we’re a few billion years old so what we taught previously (that the chronology was divinely inspired and hence correct) was wrong.