REYKJAVIK, Iceland

Financial markets are cheering the deal that emerged from Brussels early Thursday morning. Indeed, relative to what could have happened — an acrimonious failure to agree on anything — the fact that European leaders agreed on something, however vague the details and however inadequate it may prove, is a positive development.

But it’s worth stepping back to look at the larger picture, namely the abject failure of an economic doctrine — a doctrine that has inflicted huge damage both in Europe and in the United States.

The doctrine in question amounts to the assertion that, in the aftermath of a financial crisis, banks must be bailed out but the general public must pay the price. So a crisis brought on by deregulation becomes a reason to move even further to the right; a time of mass unemployment, instead of spurring public efforts to create jobs, becomes an era of austerity, in which government spending and social programs are slashed.

This doctrine was sold both with claims that there was no alternative — that both bailouts and spending cuts were necessary to satisfy financial markets — and with claims that fiscal austerity would actually create jobs. The idea was that spending cuts would make consumers and businesses more confident. And this confidence would supposedly stimulate private spending, more than offsetting the depressing effects of government cutbacks.