President Trump on Thursday signaled openness to a proposal to effectively eliminate the federal limit on government borrowing, a dramatic reversal from his view as a candidate and the long-standing position of the Republican Party that the debt limit should be raised only if other steps are taken to restrain the size of government.

On Wednesday, Trump and Senate Minority Leader Charles E. Schumer (D–N.Y.) reached what one senior White House official called a “gentlemen’s agreement” to develop a plan that would no longer require Congress to routinely raise the limit on government borrowing.

Details have not been worked out, and any plan would require approval from congressional Republicans, but the shift signifies a remarkable political evolution for Trump, who has long cheered weaponizing the debt ceiling, no matter the cost.

“I cannot believe the Republicans are extending the debt ceiling — I am a Republican & I am embarrassed!” he tweeted in 2013.

On Thursday, Trump’s approach to the debt ceiling had changed markedly.

Why does the debt ceiling exist?

“For many years people have been talking about getting rid of [the] debt ceiling altogether and there are a lot of good reasons to do that,” he said at the White House.

Trump’s discussions with Democrats on the debt ceiling could mark the end of Congress’s greatest political weapon — a legislative hand grenade that has never exploded but has unnerved financial markets for decades.

Rory Cooper, a former top adviser to House GOP leadership, said Trump’s reversal on the issue should come as no surprise, even if it insults the Republican leadership.

“There’s definitely support on the Hill on the Democratic side and even among some Republicans for doing away with debt-limit votes altogether,” Cooper said. “But President Trump is not going to be able to sustain a coalition for that so long as he is slapping leadership in the face in these negotiations.”

The U.S. government is projected to spend $4 trillion this year but bring in only $3.3 trillion through taxes and other fees. It covers the balance — known as the deficit — by issuing debt to borrow money. This debt accumulates over time, and now the federal government owes close to $20 trillion to creditors around the world.

The government can hold debt only up to a certain limit, which is set by Congress. And raising that debt limit is often politically messy, with lawmakers trying to leverage their vote in a way that can exact budget changes from the White House.

“From the economy’s perspective and from the financial markets’ perspective, removing the debt limit from that equation is probably a very, very positive thing to do,” said John Bowman, who worked on debt-ceiling issues at the Treasury Department for 15 years under presidents from both parties. “If there’s no longer uncertainty about whether or not — on a date certain — the United States has the ability to pay its bills, that’s a very, very strong good-government position to take.”

Then-House Speaker Newt Gingrich (R–Ga.) drew international attention when he flatly refused to raise it in 1995 unless President Bill Clinton agreed to a balanced-budget plan.

“I don’t care what the price is,” Gingrich said at the time. “I don’t care if we have no executive offices and no bonds for 60 days, not this time.”

It was eventually raised, but the showdown sufficiently weaponized the debt limit for both parties to use in coming years.

In 2006, then-Sen. Barack Obama (D-Ill.) refused to raise the debt ceiling for President George W. Bush, trying to score political points against a weakened White House that he was hoping to soon occupy.

“The fact that we are here today to debate raising America’s debt limit is a sign of leadership failure,” Obama said at the time. “It is a sign that the U.S. government can’t pay its own bills.”

It was eventually — barely — raised.

But sure enough, five years later, Obama as president flipped the script, pleading with lawmakers to raise the debt ceiling, saying failing to do so would lead to an economic calamity.

His showdown with congressional Republicans in 2011 took the U.S. government to the brink of defaulting on some of its obligations.

The debt limit was eventually raised after lawmakers agreed to spending caps and other budget changes, but the encounter sufficiently spooked financial markets. Credit rating agency Standard & Poor’s stripped the U.S. government of its gold-standard rating, and top Obama advisers have described the episode as one of the most frightening periods of his presidency.

Obama would later refuse to ever negotiate with Republicans on the debt ceiling again, and they acquiesced by raising it again several times.

All told, the debt ceiling has been raised 78 times since 1960, under Democrats and Republicans. It is unclear what would happen if Congress failed to raise the debt ceiling. Wall Street analysts and economists have speculated that it would lead to a large economic crisis, as the U.S. government would effectively no longer be standing behind its debt.

Trump is the first president who had openly cheered using the debt ceiling as a political straitjacket against the White House. He has endorsed many of the Republican Party’s proposals to enforce sweeping spending cuts to programs like Medicaid, leading many lawmakers to think that he would help them use the debt ceiling to cram these changes through Congress.

But since January, Trump has showed little interest in using the debt ceiling the way he wanted to before taking office.

Neither the White House nor Senate Democrats have outlined how they would propose jettisoning the debt ceiling. Vice President Pence is advocating for an idea that would essentially automatically raise the debt ceiling every time Congress approves a budget.

In the near term, the White House and many members of Congress plan to suspend the debt ceiling until Dec. 8, giving them several months to try to come up with a permanent solution.

The Senate approved the measure, 80 to 17, on Thursday, and the House was expected to approve the measure swiftly as well. But a number of prominent Republicans, including House Speaker Paul D. Ryan (R-Wis.), said Thursday that they opposed abolishing the debt ceiling in perpetuity.

Gingrich, in an interview on Thursday, said abolishing the debt ceiling would never happen because Republicans in Congress would never allow it.

“Presidents often have ideas,” he said. “Ideas aren’t programs. Programs aren’t laws. There are long jumps from the initial idea to getting it done.”

But Trump’s courtship with Democrats could give them outsize influence. Democrats have tried to stress that they are the ones who often need to deliver the votes to raise the debt ceiling, even when Republicans try to use it as negotiating leverage.

“Here, the currency of the realm is the vote,” House Minority Leader Nancy Pelosi (D-Calif.) told reporters, not signaling what her long-term preference would be. “You have the votes, no discussion necessary.”