Keeping this in mind, one cannot fail to recognize that, under the law, we were kept and guarded as under strict custody for the faith that was to be revealed. "Unto the faith that was to be revealed" means that the law did not guard us so that we should remain under it forever, but so that it might hand us over to the faith that was to be revealed. It watched over us for this faith, so that when it came, we would receive it, leaving the law behind as no longer necessary and as having fulfilled its work.
Or "unto the faith that was to be revealed" presents this thought: so that the faith that was to come could be revealed, and so that it could be revealed in us, and through us to the whole world. By keeping the law, we also kept the promise of faith as a saving treasure for the whole world. Without it, there would have been no faith. In this respect, the law has universal significance.
We bore its yoke until the very coming of faith. When faith came, it was born in us, and is now offered by us to all. This is the path by which the blessing of Abraham is now poured out upon all nations.
Blessed Augustine writes: "Someone will ask: why did the law not benefit the Jews? It did benefit them, and beyond words. What made many thousands of people suddenly sell everything and lay the price of what was sold at the Apostles' feet? The law did this, under which they had been shut up as under custody unto the faith that was to be revealed. Thus they drew near to God with such eagerness, selling all, as the Lord commanded those who wish to be perfect (see Mt 19:21). The fear of the one God held them in such confinement. And the fact that they proved to be transgressors of the law served not to harm, but to benefit those who believed. For knowledge of a most dangerous disease makes one desire the Physician more strongly and love Him more fervently. For he to whom more is forgiven loves more."
"The words 'we were guarded' and 'shut up,'" says Chrysostom, "mean nothing other than the preservation of the Jews through the commandments of the law. For the law, by holding them in fear and in life according to the law, as within certain walls, thereby preserved them for faith."
Theophylact carries the same thought further: "The law gave great protection and safeguarding to those who were under it, restraining them from many sins. As if by a wall, it enclosed men within itself and led them bound to faith. How so? By exposing sins, and being unable to free men from them, it turned their eyes against their will toward justifying faith. This faith existed even of old, but in a hidden way. Later it was revealed, when God appeared in the flesh."
Oecumenius concludes: "Here the Apostle expresses the thought that faith in Christ was predestined from ancient times. Only now has it been revealed to men through the Incarnation of God the Word."