Commons Speaker John Bercow presented a posthumous award to Second World War codebreaker Alan Turing on Tuesday evening - amid calls for the mathematician to be granted a pardon.
Presenting the Attitude magazine Icon award, Bercow said the treatment of Turing, who helped to crack the Nazi Enigma code but was then convicted for being gay and later committed suicide, was "painful, demeaning and dehumanising".
"The conviction and sentencing of Alan Turing - an innocent man - was a thoroughly shameful episode in our country’s history. As well as the physical pain Turing experienced, he was deprived of a most fundamental human instinct: to love, and to be loved," he said
Attitude magazine is celebrating the life of Turing with a special edition cover this month under the headline: "The gay man who saved the word."
Alan Turing: 'The Gay Man Who Saved The World'
Turing took his own life with cyanide in 1954 at the age of 41 - he had been sentenced to chemical castration for the crime of gross indecency.
The mathematician, one of the fathers of computer science, worked at the British government's Second World War codebreaking headquarters at Bletchley Park. He is best known for having cracked the messages sent by the German Enigma machines and is credited with saving the country from starvation.
Bercow said: "His excruciating story serves as a symbol of so much – of the terrible treatment of gay people, of the many millions of diminished lives, of the persecution of gay men who were convicted under a law which criminalised homosexuality until 1967. In fewer than 50 years we have seen the transition from the criminalisation of a type of love to the real-time prospect of equality. Sadly, our recent enlightenment, an immense credit to Parliament, has come far too late for the great man we are celebrating tonight.
"A World War II code breaker, a genius mathematician, the founder of modern computers, Alan Turing died at the age of just 41. Can you imagine what he could have achieved, what he could have done for the world, if he had lived out his life to its full potential?"
He added: "This man, this gay man, this brilliant man, who saved our country, a hero of global proportions to whom every single one of us owes so much."
The government recently signalled it would not stand in the way of a Bill designed to give Turing a posthumous pardon - overturning his conviction for being gay.
Addressing the issue in the Commons today, David Cameron said what was done at the Bletchley Park code breaking HQ was "absolutely remarkable and it was crucial in winning the Second World War".
Cameron said: "Clearly what happened to him was completely wrong and now, looking back, everyone can see that—everybody knows that. I am very happy to look at the specific issue of the pardon and respond to the hon. Gentleman, but above all what we should do is praise Alan Turing and the brave people who worked for him."
The awards ceremony also saw Ed Miliband pick up an award on behalf of all MPs who voted for gay marriage earlier this year.
Related on HuffPost:
The Morning Email helps you start your workday with everything you need to know: breaking news, entertainment and a dash of fun. Learn more