The Church does not exclude people from Holy Communion. Rather we are all free to exclude ourselves. In her teaching the Church expects those who receive Holy Communion to accept and believe everything that the Church teaches to be revealed by God.
This acceptance and belief brings about the common belief of all Catholics and it creates the communion of the faithful. The Church teaches that those who receive Holy Communion must enter this common faith and ‘fullness of communion’. Those who do not accept the Church’s teaching, like members of some other Christian traditions and those who cannot accept the teaching on marriage, exclude themselves from Holy Communion.
The Church has these expectations because to continue the mission of Christ and to be drawn increasingly into the Body of Christ is to believe as one, which is the expression of unity between all Catholics. To be willingly not part of that communion of faith and still to receive Holy Communion can be seen as a contradiction and as an inauthentic expression of loyalty to the Church and its teaching, which we believe is revealed by God.