“Have you no sense of decency?”

Those six words, uttered on June 9, 1954, by Army lawyer Joseph Welch before a Senate subcommittee, went a long way to bringing down one of the most powerful men in politics at the time, the virulently anti-communist Sen. Joseph R. McCarthy. Sixty-two years later, indecency is in vogue again. There is a hit series on Showtime called “Shameless,” and virtually every politician in America seems to have been tagged with the epithet at some point this election season.

Donald Trump's shameless philanthropy

“Newt Gingrich, shameless demagogue”

“Harry Reid's legacy of shameless partisanship”

Filmmaker Jeff Hayes even tried to raise $300,000 this year to make “Shameless, the Movie” about Hillary Clinton. (He came up $242,404.17 short.)

So if shamelessness is itself ignominious, how should we regard shame?

In the past, many psychologists theorized that shame was maladaptive and served no useful function. Earlier this year, however, anthropologists from California, Israel and the Netherlands put a positive spin on the much-maligned emotion in a study published in the Proceedings of the National Academy of Sciences.

Shame is a product of self-critique — we cannot feel shame without feeling guilty — and a consciousness of how others perceive our transgressions. For this reason, the anthropologists said, shame developed as a way of maintaining social order. Step out of line, transgress the codes of normal behavior (cultural, religious or sexual), and we risk being devalued by others in the community. Shame, or the fear of it, prevents us from acting outside the norm. In other words, it’s a healthy defense mechanism.

“Because shame (like pain) causes personal suffering and sometimes leads to hostile behavior, this emotion has been called ‘maladaptive’ and ‘ugly,’ ” the authors of the latest study wrote. “However, an evolutionary-psychological analysis of the existing evidence suggests a different view: This ugly emotion may be the expression of a system that is elegantly designed to deter injurious choices and to make the best of a bad situation.”

The possibility of shame is why we avoid outrageous acts and words, those researchers said, and when we don’t avoid them, the experience of shame afterward allows us to buy our way back into the community of man. Shame is not only normal, we need it to succeed as a society.

If that’s the case, though, what are we to make of the shameless? What kind of person never feels guilty about anything, never feels the need to apologize and appears impossible to embarrass?

Psychologists distinguish between shame and guilt in the following way: Guilt is experienced in reaction to a specific incident or behavior. It causes regret and remorse that often manifests itself in an outwardly directed behavior, such as a confession or apology. Shame, on the other hand, is directed inward. It’s not so much about doing something bad as it is about feeling bad.

In a 2014 study of recidivism in U.S. jails, researchers at George Mason University interviewed 470 inmates and asked them their feelings about guilt, shame and blame soon after they were incarcerated. Following up with 332 of those prisoners after they were released a year later, the psychologists found that those who expressed guilt about their crimes were less likely to re-offend compared with those who expressed shame. That might seem contrary to the findings of the recent study, but the George Mason researchers also discovered that the shame expressed by that second group of prisoners was accompanied by defensiveness and a tendency to blame others.

By implication then, the more someone blames others, the more shame that person must be feeling — intolerably so, which causes them to act arrogant and morally superior.

In short, according to psychologists, such individuals are that other favorite word of the political season: narcissists, people who will do anything to preserve their fragile sense of self-esteem in the face of shame’s onslaught.

In the end, shame is all a matter of degrees. A little bit is good for you — just don’t overdo it.