Then (v 37), he shows how this bread is acquired. First, he mentions the way to acquire it; secondly, the end attained by those who come to him (v 37b); thirdly, he enlarges on this (v 38).
Concerning the first, we should note that the very fact that we believe is a gift of God to us: "You are saved by grace, through faith; and this is not due to yourself, for it is the gift of God" (Eph 2:8); "It has been granted to you not only to believe in him, but also to suffer for him" (Phil 1:29). Sometimes, God the Father is said to give those who believe to the Son, as here: All that the Father give...s me shall come to me. At other times, the Son is said to give them to the Father, as in 1 Corinthians (15:24): "He will hand over the kingdom to God and the Father." We can see from this that just as the Father does not deprive himself of the kingdom in giving to the Son, neither does the Son in giving to the Father. The Father gives to the Son insofar as the Father makes a person adhere to his Word: "Through whom (that is, the Father) you have been called into the fellowship of his Son" (1 Cor 1:9). The Son, on the other hand, gives to the Father insofar as the Word makes the Father known: "I have made known your name to those you have given me" (below 17:6). Thus Christ says: All that the Father gives me shall come to me, i.e., those who believe in me, whom the Father makes adhere to me by his gift.
Perhaps some might say that it is not necessary for one to use God's gift: for many receive God's gift and do not use it. So how can he say: All that the Father gives me shall come to me? We must say to this that in this giving we have to include not only the habit, which is faith, but also the interior impulse to believe. So, everything which contributes to salvation is a gift of God.
There is another question. If everything which the Father gives to Christ comes to him, as he says, then only those come to God whom the Father gives him. Thus, those who do not come are not responsible, since they are not given to him. I answer that they are not responsible if they cannot come to the faith without the help of God. But those who do not come are responsible, because they create an obstacle to their own coming by turning away from salvation, the way to which is of itself open to all.
Then (v 37b), the end attained by those who come is mentioned. For some might say, "We will come to you, but you will not receive us." To exclude this he says, the one who comes to me, by steps of faith and by good works, I will not cast out. By this he lets us understand that he is already within, for one must be within before one can be sent out. Let us consider, therefore, what is interior, and how one is cast out from it.
We should point out that since all visible things are said to be exterior with respect to spiritual things, then the more spiritual something is the more interior it is. What is interior is twofold. The first is the most profound, and is the joy of eternal life. According to Augustine, this is a sweet and most interior retreat, without any weariness, without the bitterness of evil thoughts, and uninterrupted by temptations and sorrows. We read of this: "Share the joy of your Lord" (Mt 25:21); and, "You will hide them in the secret of your face," that is, in the full vision of your essence (Ps 30:21). From this interior no one is cast out: "He who conquers, I will make him a pillar in the temple of the living God; and he will no longer leave it" (Rv 3:12), because "the just will go to everlasting life," as we see from Matthew (25:46). The other interior is that of an upright conscience; and this is a spiritual joy. We read of this: "When I enter into my house I will enjoy repose" (Wis 8:16); and "The king has brought me into his storerooms" (Sg 1:3). It is from this interior, that some are cast out.
So, when our Lord says, the one who comes to me I will not cast out, we can understand this in two ways. In one way, those who come to him are those who have been given to him by the Father through eternal predestination. Of these he says: the one who comes to me, predestined by the Father, I will not cast out: "God has not rejected his people, the people he chose" (Rom 11:2). In a second way, those who do go out are not cast out by Christ, rather, they cast themselves out, because through their unbelief and sins they abandon the sanctuary of an upright conscience. Thus we read: I will not cast out such; but they do cast themselves out: "You are the burden, and I will cast you aside, says the Lord" (Jer 23:33). It was in this way that the man who came to the wedding feast without wedding clothes was cast out (Mt 22:13).
Source: Commentary on John