Since the promulgation of the Gospel, the law of baptism became obligatory on all who would be saved, hence Christ's words in St. Mark 16:16 and in St John 3:5 to Nicodemus, foretelling this law, and his words in St. Matthew 28:19, putting the law into effect.
Catechism of the Council of Trent, p. 171: "Holy writers are unanimous in saying that after the Resurrection of our Lord, when He gave His Apostles the command to go and teach all nations: baptizing them in the name of the Father, and of the Son, and of the Holy Ghost, the law of Baptism became obligatory on all who were to be saved."
St. Dismas died before this time. Furthermore, there is no clear proof that he wasn't baptized, and St. Augustine also entertained the thought that he may have been.
Nevertheless, Pope Eugene IV infallibly tells us that there is no such thing as baptism of blood for those unbaptized (as they are outside the Church), or even the baptized who are heretics or schismatics.
Pope Eugene IV, Council of Florence, 1442, ex cathedra: "It firmly believes, professes and preaches that all those who are outside the Catholic Church, not only pagans but also Jєωs or heretics and schismatics, cannot share in eternal life and will go into the everlasting fire which was prepared for the devil and his angels, unless they are joined to the Catholic Church before the end of their lives; that the unity of the ecclesiastical body is of such importance that only for those who abide in it do the Church's sacraments contribute to salvation and do fasts, almsgiving and other works of piety and practices of the Christian militia produce eternal rewards; and that nobody can be saved, no matter how much he has given away in alms and even if he has shed his blood in the name of Christ, unless he has persevered in the bosom and the unity of the Catholic Church."
Anybody who dies unbaptized, dies unjustified, since the instrumental cause, or the agency by which it is effected in a soul, of justification is the sacrament of baptism.
Pope Paul III, Council of Trent, Session 6, Chapter 7, ex cathedra: "Of this Justification the causes are these... the instrumental cause is the sacrament of baptism, which is the sacrament of faith, without which (faith) no man was ever justified..."
Without faith it is impossible to please God (and therefore to be justified, sanctified, merit eternal life, etc.), so naturally, one must be of the faithful to be saved, not merely a catechumen.
Pope Innocent III, Lateran Council IV, 1215, ex cathedra: "There is indeed one universal Church of the faithful, outside of which nobody at all is saved, in which Jesus Christ is both priest and sacrifice."
The argument that some people make about certain saints being martyred while still catechumens (St. Emerantiana, for example) is first of all not based on any infallible teachings of the Church, but fallible docuмents alone, and second of all, just because someone is a catechumen, does not mean that they have not already been baptized, as shown by the following canon from the Council of Nicaea:
Pope Council of Nicaea, AD 325, Canon 2: "Since, either through necessity or through the importunate demands of certain individuals, there have been many breaches of the church's canon, with the result that men who have recently come from a pagan life to the faith after a short catechumenate have been admitted at once to the spiritual washing, and at the same time as their baptism have been promoted to the episcopate or the presbyterate, it is agreed that it would be well for nothing of the kind to occur in the future. For a catechumen needs time and further probation after baptism, for the apostle's words are clear: "Not a recent convert, or he may be puffed up and fall into the condemnation and the snare of the devil". But if with the passage of time some sin of sensuality is discovered with regard to the person and he is convicted by two or three witnesses, such a one will be suspended from the clergy. If anyone contravenes these regulations, he will be liable to forfeit his clerical status for acting in defiance of this great synod."