In ancient times, suicide sometimes followed defeat in battle, to avoid capture and possible subsequent torture, mutilation, or enslavement by the enemy. The Caesarean assassins Brutus and Cassius, for example, killed themselves after their defeat at the battle of Philippi. Insurgent Jews died in a mass suicide at Masada in 74 CE rather than face enslavement by the Romans.
During World War II, Japanese units would often fight to the last man rather than surrender. Towards the end of the war, the Japanese navy sent kamikaze pilots to attack Allied ships. These tactics reflect the influence of the samurai warrior culture, where seppuku was often required after a loss of honor. It is also suggested that the Japanese treated Allied POWs harshly because, in Japanese eyes, by surrendering rather than fighting to the last man, these soldiers showed they were not worthy of honorable treatment. In fact, the Japanese unit in Singapore sentenced an Australian bombing unit to death in admiration for their bravery.
In modern times, suicide attacks have been used extensively by Islamist militants. However, it is important to note that suicide is strictly forbidden by Islamic law, and the Muslim clerics who organize these attacks do not regard them as suicide, but as martyrdom operations. Clerics argue the difference to be that in suicide a person kills himself out of despair, while in a martyrdom operation a person is killed as a pure act.
Spies have carried suicide pins to use when captured, partly to avoid the misery of captivity, but also to avoid being forced to disclose secrets. For the latter reason, spies may even have orders to kill themselves if captured – for example, Gary Powers had a suicide pin, but did not use it when he was captured.