On Tuesday, U.S. Bankruptcy Judge Steven Rhodes upheld Detroit's eligibility to file for Chapter 9 bankruptcy, and then gave some bad news to the ailing city's municipal workers and retirees: Their pension funds are on the block.

"In the long-running story of Detroit as Humpty Dumpty," says Laura Berman in The Detroit News, this "was another of the accumulating historic days confirming the city's long, slow fall to the inevitable."

Tuesday's ruling opened the way for Detroit's state-appointed emergency manager, Kevyn Orr, to finalize his plan for who will face the inevitable brunt of the massive write-down of the city's $18 billion in debt. But Rhodes also opened up a sort of Pandora's box for public-employee pension funds around the country.

"Pension benefits are a contractual right and are not entitled to any heightened protection in a municipal bankruptcy," Rhodes said in his 90-minute summary of Detroit's fiscal and residential woes. The "heightened protection" in this case is Michigan's Constitution, which appears to explicitly shield public pensions from such cuts. The pensions of about 23,000 retirees are now up for grabs.

"This is one of the strongest-protected pension obligations in the country here in Michigan," Bruce Babiarz, a spokesman for the Detroit Police and Fire Retirement System, tells The New York Times. "If this ruling is upheld, this is the canary in a coal mine for protected pension benefits across the country. They're gone."

Unions and pension funds will appeal Rhodes' ruling, and a Supreme Court ruling may well be the final arbiter of this apparent conflict between federal bankruptcy law and Michigan's Constitution. Even if Rhodes' pension fund ruling stands, though, Orr's restructuring plan will have to be deemed feasible by the federal judge — and survive the gamut of challenges and proposals from unions and the other 100,000 creditors listed in Detroit's bankruptcy filing.

Assuming Orr largely gets his way, here are the parties and assets most likely to take a hit in Detroit's unprecedented bankruptcy restructuring:

Municipal employees and pensioners
The most high-profile losers — and, arguably, most sympathetic — are the more than 22,000 retired firefighters, cops, municipal clerks, and other public employees whose monthly pension checks will almost certainly be reduced after the restructuring is complete. The 10,000 active city workers will take a hit, too, either through increased contributions to their pension and health-care costs or a decrease in their promised retirement benefits.

Detroit has already stopped paying into its pension funds. "Orr has not said specifically how he would alter pension payments, but he has said some adjustment would need to be made to deal with $3.5 billion in unfunded liabilities," say Alana Semuels and Michael Muskal at the Los Angeles Times. "Unions say that could mean cutting pensions in half." The funds had assets with a market value of $4.3 billion in June 2012.

Retired public workers received payments averaging about $19,000 a year before Orr declared bankruptcy on behalf of the city. "You might wonder what an aging person can do on $19,000 per year," says Bailey McCann at CivSource. Well, "consider less than that. Consider as well, some of these people may also hold bonds."

A good chunk of Detroit's 100,000 creditors are holders of the city's municipal bonds and notes. In June, Orr warned them that about $576 million worth of limited tax general obligation debt, plus another $65 million in unlimited tax general obligation debt, will be considered unsecured — meaning that bondholders will likely take a "haircut" on their investment.

Though the bonds are "widely considered as safe as secured debt," the city is "proposing that investors in these so-called 'limited tax' bonds accept as little as pennies on the dollar," says CNBC's John W. Schoen. That's roiling Detroit bondholders, but also investors in the $3.7 trillion municipal bond market.

"People now have to go in wide-eyes-open buying those kinds of assets — knowing that they aren't guaranteed," Los Angeles bankruptcy lawyer Randye Soref tells CNBC.

That doesn't necessarily mean that Detroit bondholders have to take this lying down, says CivSource's McCann. "Bondholders and pensioners can both protest and refuse to agree to haircuts offered, although what that will result in is unclear."

And while Orr proposes paying them pennies on the dollar, that doesn't mean bondholders will actually take much of a loss, says Reuters' Karen Pierog. "Detroit bondholders can receive full payment on general obligation debt thanks to insurance policies purchased by the city."

Let's go ahead and add those insurers — Assured Guaranty, National Public Finance Guarantee Corp., Ambac Assurance Corp., and Syncora Guarantee — to the list of losers in Detroit's bankruptcy.

Wall Street banks
If retired cops and firefighters are the most sympathetic losers here, probably the least warm-and-fuzzy are the big Wall Street banks. If bankruptcy is supposed to exorcize the ghosts haunting Detroit's red-stained ledger, "before they leave, those ghosts are looking for the biggest payouts they can negotiate," says CNBC's Schoen. And "standing in the front of the line are UBS and Bank of America's Merrill Lynch unit."

Those banks alone are costing the city $50 million a year — about a quarter of its budget shortfall — through interest-rate swaps they sold Detroit and other cities to hedge against rising interest rates. These swaps "have become a financial albatross for hundreds of state and local governments as interest rates fell to the floor," explains Schoen.

The Wall Street titans, of course, "seem to have negotiated a pretty good deal," offering to settle for about 75 cents on the dollar, says Detroit bankruptcy lawyer Douglas Bernstein, who is following the case closely. "But the other creditors are saying they shouldn't be treated as secured creditors. That test remains to be seen."

Art and other city assets
Basically, everything owned by the city of Detroit is potential collateral for the city's various creditors — and that includes Detroit's lucrative Water and Sewerage department and the well-regarded art collection at the city-owned museum the Detroit Institute of Arts (DIA).

On Tuesday, Orr reiterated that he expects DIA to pony up about $500 million, either through the sale of some of its masterpieces or some other financial arrangement, like renting them out. He has hired Christie's auction house to assess the value of the museum's 2,800 city-owned works, and on Tuesday he said that the fair-market estimate for the 439 most valuable works — including landmark paintings by Van Gogh, Matisse, Rembrandt, and Brueghel — came in at a disappointingly low $1 billion to $2 billion.

That's way too low, according to creditors, who are demanding a second opinion. They're probably right, says Mark Stryker at the Detroit Free Press. In May, the Free Press asked art dealers and auction houses to assess the worth of 38 prominent works at the DIA, and "the tally was $2.5 billion."

Of course, selling art won't solve the city's structural problems — a point emphasized by Judge Rhodes. "No other American museum the size of the institute has ever confronted such a threat to the integrity of its collection," says Randy Kennedy at The New York Times. But "the fate of the city's art collection — one of the finest in the country" — is about more than just dollars and cents. In a city that's lost half its population and many of its services, you can still cut to the point where no blood comes out.

"Unlike a corporation, you can't liquidate a city — at least in theory," says CivSource's McCann. "Close watchers of Detroit could argue though, if you were going to try we're getting pretty close."