Cleaning up after a coup is dirty work. Turkish President Recep Tayyip Erdogan has said he will consider the death penalty for the plotters - of whom there may be thousands. That would certainly send a tough message to anyone who sees the near-miss coup as evidence that his democratically elected government is vulnerable.
But there's a catch: Turkey abolished the death penalty in 2004. And in 2006, it ratified a European treaty that also outlaws capital punishment.
To change the law, Mr Erdogan wouldn't just need a vote in the Turkish Parliament. His country would also have to withdraw from the international treaty, alienating itself from Europe and guaranteeing that it could not join the European Union (EU) unless it changed its laws back again.
The conflict between looking strong and looking democratic could not be framed more starkly.
The challenge facing Mr Erdogan is particularly unusual. It's rare in the modern era for a democracy - even a democracy flirting with authoritarianism - to survive a serious coup attempt. Indeed, I can't come up with a recent example.
Egypt's sole democratically elected president, Mr Mohamed Mursi of the Muslim Brotherhood, was taken out by the military coup of 2013 that brought General Abdel-Fattah El-Sisi to power. Like most newly self-appointed dictators, Mr Sisi has had no compunction about jailing and executing opponents.
A democratically elected government that has survived a coup attempt is in a more complicated position. It needs to convey strength. But it also needs to remind the public and the world that it's democratic. Punishing coup plotters too harshly, or without due process, undercuts that message. Ultimately, it could undercut the very democratic legitimacy that helped the government survive in the first place.
The death penalty quandary dramatises Turkey's situation. Treason is a serious crime. If you believe the death penalty is morally permissible under certain circumstances, you might well think that one of those circumstances includes punishment for trying to subvert democracy itself. The coup attempt in Turkey also resulted in hundreds of deaths, for which the plotters, or at least their leaders, would seem to be morally and criminally responsible.
A democratically elected government that has survived a coup attempt... needs to convey strength. But it also needs to remind the public and the world that it's democratic. Punishing coup plotters too harshly, or without due process, undercuts that message.
In the United States, if active-duty military officers attempted a coup in which people were killed and the Capitol was bombed, it's a pretty safe bet that prosecutors would seek the death penalty against, at least, some of the conspirators.
From Mr Erdogan's perspective, the need to establish order - by means of an iron fist, if necessary - seems especially pressing. A failed coup can be interpreted in two opposite ways. It can be seen as evidence that the government was strong enough to survive; or it can be read as a blueprint for how to do it better the next time.
If reports are accurate that rebel F-16 jets had Mr Erdogan in their sights and didn't engage because his aircraft was protected by his own fighters, then the lesson for future coup plotters is clear: shoot first and ask questions later. No doubt that's why, in early interviews, Mr Erdogan has emphasised his intention to use harsh, but legal, measures to crack down.
Turkey's democracy is fragile. Before the coup attempt, the fragility was mostly visible due to Mr Erdogan's rising authoritarianism. The defeated coup attempt shows that the anti- Erdogan military is just as vulnerable.
Yet, changing Turkish law to reinstate capital punishment would be risky. Domestically, Mr Erdogan may have the votes. His AK Party doesn't have a majority on its own, but it's part of the majority coalition in the Grand National Assembly. Arguably, the whole coalition may see itself as vulnerable after the coup, and might join the AK Party in voting for the change.
The more serious challenge is the international one. The EU has a strict rule that bans its members from allowing capital punishment. Indeed, Turkey's move to eliminate the practice, which took place under the AK Party government, was widely understood to be motivated by the desire for eventual EU accession. Turkey in 2006 officially adopted Article 13 of the European Convention on Human Rights (ECHR), the treaty that abolishes the death penalty.
Under international law, a country that ratifies a treaty, ordinarily, has the right to withdraw from the treaty. So in principle, Turkey could probably withdraw from the death penalty article of the convention. Before she became Prime Minister, Mrs Theresa May advocated for Britain to withdraw from the ECHR. So withdrawal from the treaty isn't unthinkable.
Doing so involves a tricky calculus. Turkey can't become an EU member without subscribing to the whole convention. But at the moment, that's extremely improbable for Turkey anyway. The door to full membership had largely been shut even before the Syrian refugee crisis. In today's anti-migrant environment, it's almost impossible to imagine other European countries allowing Turks the freedom to settle in their countries.
And the coup attempt can't be a good sign for Turkey joining the EU, either. The EU prides itself on the political stability of its member states.
Mr Erdogan could therefore calculate that reinstating the death penalty is worth the cost. If, in the future, Turkey wanted to try again to gain EU membership, it could change its laws back and re-ratify the treaty.
Such are the unenviable challenges of a coup clean-up. It would be nice if Mr Erdogan would now double down on liberalism and democracy. Don't count on it.
A version of this article appeared in the print edition of The Straits Times on July 21, 2016, with the headline 'Turkey will pay a price for executing traitors'. Print Edition | Subscribe
We have been experiencing some problems with subscriber log-ins and apologise for the inconvenience caused. Until we resolve the issues, subscribers need not log in to access ST Digital articles. But a log-in is still required for our PDFs.