A primer for those who prefer knowing to opining
Here's the Shorter Version: First, Canon 916. There are lots of mortal sins out there; if you commit any one of them, you're not supposed to go to Communion. It's your obligation to stay away. Next, Canon 915. Some mortal sins are committed under circumstances that, if the Church finds out about them, not only are you supposed to the stay away from Communion, but the Church is supposed to turn you away if you try to receive. Finally, Canon 1331. A few mortal sins are serious crimes under canon law; if you commit one of those, you can suffer the penalty of excommunication, and one of the consequences of excommunication is, you can't go to Communion.
That seems pretty straight-forward, no? Still, if you want more, read the Longer Version:
1. Canon 916: "A person who is conscious of [having committed] grave sin is not to . . . receive the Body of the Lord without previous sacramental confession. . ."
This canon only expresses what is already required by moral theology: anyone who is aware of having committed a grave sin of any sort and who has not repented of and confessed the sin must not go to Communion. This canon does not lend itself to enforcement by ecclesiastical authority for many reasons, including the impossibility of Church officials knowing just who committed what grave sin. Of this canon, it may be said "One who commits grave sin makes himself ineligible to receive Communion."
2. Canon 915: "Those who have been excommunicated or interdicted after the imposition or declaration of the penalty and others obstinately persevering in manifest grave sin are not to be admitted to holy communion."
Prescinding from the inartful ordo presentationis of the Code, this canon builds on what Canon 916 will have established as a personal obligation, but here goes on to require ecclesiastical officials, under specific circumstances, to withhold the Eucharist from some persons whose grave sins meet the additional criteria set out in Canon 915. It is self-evident from the terms of this canon that some people who are not excommunicated are nevertheless prohibited from receiving the Eucharist and that this prohibition is meant to be enforced. Of this canon it may be said, "One who commits grave sin under certain circumstances makes himself liable, upon verification of the facts, to the actual withholding of the Eucharist by ecclesiastical officials."
3. Canon 1331: "An excommunicated person is forbidden: (1) to have any ministerial participation in celebrating the sacrifice of the Eucharist or any other ceremonies of worship whatsoever; (2) to celebrate the sacraments or sacramentals and to receive the sacraments; (3) to exercise any ecclesiastical offices, ministries, or functions whatsoever or to place acts of governance . . ."
This canon sets out that denial of Holy Communion is one (perhaps the most notable, but nevertheless just one) of the consequences of being excommunicated. Other canons establish that excommunication can only be incurred for certain kinds of grave offenses, all of which offenses are indeed gravely sinful actions, but sins that have additionally been criminalized under canon law.
The virtually unanimous opinion among canon lawyers is that no canon, not even Canon 1398 on abortion, makes pro-abortion legislative activity an excommunicable offense. Therefore, the many complications arising from the fact that some excommunications are latae sententiae (automatic) while others are not, do not impact this discussion. Of this canon it may nevertheless be said, "Anyone who, as a result of his actions, has been excommunicated, suffers a variety of canonical consequences, including but not limited to being barred from receiving the Eucharist."
Keeping these three points clear is a prerequisite for responsible discussion of this vital matter.
At this point, my opinions:
(1) Depending on the facts of the specific case, support for even one pro-abortion legislative proposal can be grave matter sufficient, in accord with the usual criteria (especially knowledge and consent), to make one ineligible to approach Holy Communion under Canon 916. Individual Catholics have to make that decision in accord with the principles of a sound conscience, and they are accountable to God for what they decide.
(2) Depending on the character (i.e., degree, duration, etc.) of one's support for pro-abortion legislative initiatives, such activity can be sufficient basis for ecclesiastical officials to prohibit a specific person from approaching Holy Communion under Canon 915. Church officials have to make this determination in accord with the principles of canon law and are accountable, ultimately to God, for what they decide.
(3) Under the current Code, no one can be excommunicated (automatically or otherwise) for pro-abortion legislative activity. Such activity is nevertheless potentially punishable under other canons (e.g., Canon 1369) albeit not with excommunication. Moreover, particular legislation, personal precept, or contempt for lesser penalties, might make pro-abortion legislators liable to excommunication in the future. To my knowledge, though, none of these options is being pursued.