Slovenia Prime Minister Miro Cerar resigned late Wednesday over a Supreme Court decision nullifying a referendum in favor of a major railroad project.
"This was the straw that broke the camel's back," Cerar said in his resignation note to parliament. "The second track project has been hit by another blow taken by those who want to stop Slovenia's positive development. I don't want to be part of such stories."
He plans to submit his resignation to President Borut Pahor Thursday.
Voters in September approved the $1.2 billion project to extend a key rail line from an Adriatic port to the Italian border.
But the Slovenian Supreme Court ordered a new vote, saying the government unfairly influenced voters to approve the project.
Cerar said the rail line would be of "strategic importance for the development of Slovenia."
Cerar says his center-left coalition is leaving the country in much better economic shape than it was when it took power in 2014.
Parliamentary elections are set for June, but Cerar's resignation may move them up.