Malaysian Prime Minister, Dr Mahathir Mohamad, stoked further legal controversy over homosexuality when he denounced the caning of two Muslim women for attempting lesbian sex.

His comment came after the Indian Supreme Court ruled homosexuality as legal.

The caning sentence had sparked in Malaysia outrage and raised fears about the treatment of the lesbian, gay, bisexual and transgender (LGBT) community.

The women had pleaded guilty to charges under Islamic laws forbidding lesbian sex. They were caned on Monday in front of dozens of people at a sharia court in Terengganu, a conservative state in the east, prompting an outcry from human rights activists, who described the punishment as torture.

Mahathir’s government has appeared divided about the LGBT community, while the premier himself had been silent on the caning and recent attacks on transgender people and marginalised groups in the Muslim-majority country.

In a video posted on his Twitter account, Mahathir said the caning “did not reflect the justice or compassion of Islam”.

It was the women’s first offence, he said, which warranted a lighter sentence, such as counselling.

“This gives a bad impression of Islam,” the 93-year-old leader said. “It is important that we show Islam is not a cruel religion that likes to impose harsh sentences to humiliate others.”

The LGBT community is routinely persecuted in Malaysia, where it is seen as a threat to conservative values.

Mahathir’s government swept into power in May after campaigning on a reform agenda, but has been unconvincing in its handling of matters relating to race, religion and minorities in the multi-racial country.

The caning followed a series of incidents in recent weeks that civil rights groups said illustrate growing hostility against gay and transgender people.

Mahathir’s comment got a prompt response from a Muslim leader, Tan Sri Harussani Zakaria, the Perak Mufti, who urged all parties to look at the legal and not political benefits of the public caning of the women.

Harussani said the caning was meant to teach the offenders a lesson and the caning did not maim, torture or injure them.

“There is a way to do it, of which the cane was not raised high and it was not brutal. From an Islamic perspective, the caning was meant to teach them a lesson. That was why the caning was open to the public as it was meant to teach and act as a deterrent to others.

“The offenders meanwhile, will not repeat the act or risk being caned again,” Harussani told reporters after delivering a keynote address at the Wacana Kesejagatan Ummah 2018.

Last month, a gay bar in Kuala Lumpur was raided by police and religious enforcement officials, while a transgender woman was beaten up by a group of assailants in Seremban, near the capital.

The minister in charge of Islamic affairs also came under fire, including from other ruling party lawmakers, after he ordered the removal of portraits of two LGBT activists from an art exhibition.

Malaysia describes oral and anal sex as against the order of nature. Civil law stipulates jail for up to 20 years, caning and fines for offenders, although enforcement of the law is rare.

Muslims are also governed by state-level Islamic laws, most of which carry provisions outlawing same-sex acts.(NAN)