Viaticum within Mass is preferred above viaticum within a word and communion service. A Mass is subject to the same liturgical regulations as any other Mass of its kind: marriage, confirmation, ordination. The priest and planners may choose one of two Masses:
184. When viaticum is received within Mass, the ritual Mass for Viaticum or the Mass of the Holy Eucharist may be celebrated. The priest wears white vestments. The readings may be taken from The Lectionary for Mass or from part III of this ritual, unless the dying person and those involved with the priest in planning the liturgy choose other readings from Scripture.
Even then, there is a practical Roman sensibility of what works for the dying person and other planners.
A ritual Mass is not permitted during the Easter triduum, on the solemnities of Christmas, Epiphany, Ascension, Pentecost, Corpus Christi, or on a solemnity which is a holy day of obligation. On these occasions, the texts and readings are taken from the Mass of the day. Although the Mass for Viaticum or the Mass of the Holy Eucharist are also excluded on the Sundays of Advent, Lent, and the Easter season, on solemnities, Ash Wednesday, and the weekdays of Holy Week, one of the readings may be taken from the biblical texts indicated above. The special form of the final blessing may be used and, at the discretion of the priest, the apostolic pardon may be added.
Does this mean you have to wait for the next day? Not at all. The final eucharistic celebration may of course be celebrated on these solemnities. You just use the festive readings of the day, and give Communion to the person as you would at any Mass. We’re hoping there would be a sensible approach of not planning special readings when the priest knows Viaticum will have to be celebrated on such a solemnity.
One final practical note, namely, that penance should be celebrated at a different time. But the pastoral leeway is granted for times of need:
185. If the dying person wishes to celebrate the sacrament of penance, it is preferable that the priest make himself available for this during a previous visit. If this is not possible, the sacrament of penance may be celebrated before Mass begins.