Malaysia’s opposition alliance has named 92-year-old former prime minister Mahathir Mohamad as its prime ministerial candidate for upcoming general elections to boost its chances of wrestling power from a coalition that has ruled since independence.

The announcement by the four-party Hope Alliance puts an end to squabbling over the thorny issue and is seen as a major show of unity ahead of polls that must be held by August, but are widely expected in the second quarter of 2018.

Prime Minister Najib Razak has clung to power despite a corruption scandal that involved hundreds of millions of dollars passing through his bank accounts.

Support for his ruling National Front coalition has dwindled in the last two elections. In 2013, the coalition lost the national popular vote for the first time to the opposition.

Analysts said the opposition still faces an uphill battle due to party infighting, unfavourable electoral boundary changes and strong support for the government from rural ethnic Malays.

“Clearly the opposition is trying hard to prove that they are united. It is a potential risk (to Najib) as Mahathir is still attractive to the Malays but the government still has the upper hand due to an unlevel playing field,” said Wan Saiful Wan Jan, of think-tank Institute for Democracy and Economic Affairs.

Government leaders scorned the candidacy of Mahathir, who will be the world’s oldest leader if the opposition wins.

Government minister Abdul Rahman Dahlan called his candidacy a stumbling block to the opposition’s reform agenda.

“It’s laughable to appoint Mahathir as the next PM and expect him to implement those reforms,” he tweeted. “It’s a tragedy to their own cause....anyway, I thank them for making it even easier for us to win the upcoming general election.”

Mahathir, Asia’s longest-serving leader for 22 years before stepping down in 2003, was an authoritarian who made a high-profile return to politics in a bid to oust his protege Najib.

Najib has sacked critics in his own government including an attorney general and deputy prime minister and muzzled the media since the scandal erupted two years ago.

The US and several other countries are investigating allegations of embezzlement and money-laundering at a state investment fund.