Batman started off as a somewhat ruthless vigilante who had no compunction about murdering criminals, often with firearms. Later, his backstory was retconned to make him be staunchly opposed to guns and murder due to the nature of his parents' deaths.
However, his arch-nemesis the Joker has no such scruples, and in the Batman universe has killed at least 543 people. As has been discussed ad infinitum, most of these deaths would have been prevented if Batman had simply executed the Joker instead of repeatedly locking him up in Arkham Asylum (aka the most useless prison ever built). But of course, this most logical course of action, that would've saved many more lives, is precluded by the arbitrary code of honour.
However, there is another way that Batman could have prevented the Joker (and indeed any other murdering supervillain he's tangled with and sent to Arkham Asylum multiple times) from being a menace ever again: physically injuring them in a way that makes them incapable (or at least, far less capable) of escaping, never mind committing the crimes that have led to them being incarcerated. I'm talking some pretty gruesome actions such as beating them into a coma, rendering them paraplegic or quadriplegic, or slicing off their limbs.
Does Batman's honour code prevent him from saving innocent lives, by maiming his enemies to prevent them from taking those lives?