CHICAGO (CBS) — The Illinois Supreme Court has struck down the Emanuel administration’s attempt to bail out the severely underfunded pension systems for city workers and laborers.

Last summer, a Cook County judge ruled a 2014 state law overhauling those two pension funds to be unconstitutional. On Thursday, the state’s highest court upheld that ruling. Five of the seven justices concurred in the ruling. Justices Anne Burke and Charles Freeman recused themselves from considering the case.

In 2014, the Illinois General Assembly passed legislation requiring city workers and laborers to pay increased pension contributions, and lowering the annual cost-of-living increases for retirees. In exchange, the city agreed to increase its annual contributions to the pension funds.

Most of the city’s unions agreed to the changes, but some did not, and opponents sued the city, arguing the changes violated a clause of the Illinois Constitution that states public employee pension benefits “shall not be diminished or impaired.”

The city argued the changes did not violate the Illinois Constitution, because the law would require significant increases in the city’s contribution to the pension funds, and avoid bankruptcy, which it expects within 15 years without the changes.

The Illinois Supreme Court rejected that argument, ruling the city’s position “would lead to an absurd and unjust result.”

In the opinion written by Justice Mary Jane Theis, the justices ruled reducing the benefits paid to retired public employees cannot be offset by guaranteeing the solvency of the pension funds, since the Illinois Constitution requires public employees receive the full pension benefits they were promised when they retire.

“The General Assembly and the City have been on notice since the ratification of the 1970 Constitution that the benefits of membership must be paid in full, and that they must be paid without diminishing or impairing them,” the court wrote. “Since participants already enjoy that legal protection, we reject the notion that the promise of solvency can be ‘netted’ against the unconstitutional diminishment of benefits.”

The two funds are about $8 billion short of what is required to cover pension benefits. Workers such as librarians, health care aides and non-teaching public school employees are covered by one fund, while city laborers are covered by another.

In a prepared statement, Mayor Rahm Emanuel said he disagrees with the ruling, but will continue to work with labor unions to preserve the pension funds, protect taxpayers, and ensure the city’s financial well-being.

“Though disappointing, this ruling does not change my commitment to ensuring employees and retirees have a secure retirement without placing the full burden on Chicago taxpayers,” the mayor said.

Ald. Roderick Sawyer (6th) chairman of the Chicago City Council’s Black Caucus, said the decision means aldermen must get started on finding a solution to the city’s pension crisis.

“Now it’s up to us to kind of roll up our sleeves and find a way to cover these workers’ pensions. I mean, we cannot deny them their due. They worked to secure these, and we need to work hard to make sure that we can satisfy those and the ones that are coming through,” he said.

AFSCME Council 31, the Chicago Teachers Union, the Illinois Nurses Association and Teamsters Local 700 issued a joint statement praising the ruling, and accusing the city of causing the pension crisis by failing to adequately fund the pension systems while workers “were faithfully paying their share.”

“It’s long past time for elected officials to stop trying to end-run the constitution and shirk their duty. Pension funding challenges require funding solutions that must be constitutional and fair to all. Our unions are committed to working with anyone of good faith toward that goal,” the unions said.

The legislation did not address pension funds for Chicago police officers, firefighters, or teachers – all of which also are woefully underfunded.