The Pledge (1981)
Set in England in 1790 the film begins by showing a pedlar walking through the Northern hills. He comes across a dead highwayman hanging from a gibbet. At a nearby inn the highwayman's former henchmen plot to fulfil their pledge to bury the body in a churchyard and send the highwayman's soul to paradise. In flashback we see the highwayman was a rapist, murderer and thief. In the black of night his comrades in crime cut him down and bury him in the tomb of an archbishop to free his soul. The film ends as the soul enters heaven to a chorus of angels.