Barack Obama delivers his farewell address in Chicago. Photo: Zbigniew Bzdak/TNS via Getty Images

In his farewell address, Barack Obama gave a speech that was very different from what he would have delivered if his successor were Hillary Clinton, or even any of the 16 Republicans who tried and failed to win their party’s nomination. His speech devoted only the most perfunctory attention to his many accomplishments in office. Instead, he delivered a stirring call to his country to defend its democracy against a looming threat — one he never named, even elliptically, but whose identity was clear in the references laced throughout his speech.

Obama’s address walked through the currents that had produced the Trump presidency, warning of their dangers and offering solutions. He suggested rampant income inequality and stagnant growth as sources of political instability. “Stark inequality,” he warned, made struggling people believe “that their government only serves the interests of the powerful — a recipe for more cynicism and polarization in our politics.” Racism and racial polarization, too, allowed a politics where any economic issue would be “framed as a struggle between a hardworking white middle-class and undeserving minorities” — framed, Obama implied, but did not state, by right-wing demagogues. And Obama argued that the sorting of America into hostile tribes, where all sides increasingly shun those with different views and see only news that confirms their beliefs, makes compromise impossible.

Obama has made versions of these arguments before. But from this beginning he launched into a more direct attack on Trumpism. He insisted on a respect for science and reason, noting that the spirit of the Enlightenment formed the very basis for democratic government. The philosophy of democratic government is premised on citizens using facts to arrive at truth. He cited the denial of the findings of climate science, a hallmark of Trump and several of his advisers, as the ultimate case of anti-empiricism.

Obama defined the threat to liberal democracy as an ideological struggle almost akin to the Cold War. The demise of the Soviet Union created a unipolar world, in which the presidents of the post–Cold War era presented democracy as an unchallengeable idea spreading across the globe. Since 9/11, George W. Bush, and then Obama, have mostly defined the threat to the liberal order as coming from radical jihadism. But Obama took pains to include illiberal states in the ranks of the enemies of democracy. The liberal order, he said, “is now being challenged — not just by radical Islam but also autocrats.”

Obama defended pluralism, reminding white Americans that their ancestors from Italy, Ireland, and Poland were seen as foreign threats who could not be assimilated, like Latino immigrants today. He received probably his longest ovation during the speech by rejecting discrimination against Muslim-Americans. Obama attacked populism for fostering indiscriminate suspicion of elected officials: “We weaken those ties when we define some of us as more American than others; when we write off the whole system as inevitably corrupt, and blame the leaders we elect without examining our own role in electing them.” And he urged Americans to “insist on the principles of transparency and ethics in public service.”

The political style described here by Obama is the brand of right-wing nationalism on the march throughout Europe, but especially recognizable as Trumpism: It involves stoking fear against outsiders and minorities, and sweeping claims that the system is rigged, that enable actual (rather than imagined) corruption. Obama called upon the country to fight it. The most remarkable passage of the speech, one that could hardly have been imagined a year ago, came when the departing president called for a defense of the Constitution:

Our Constitution is a remarkable, beautiful gift. But it’s really just a piece of parchment. It has no power on its own. We, the people, give it power – with our participation, and the choices we make. Whether or not we stand up for our freedoms. Whether or not we respect and enforce the rule of law. America is no fragile thing. But the gains of our long journey to freedom are not assured.

This last sentence was especially chilling. Optimism about the course of America has long been a hallmark of Obama’s worldview. He sees in American history a long, jagged path to a better world that makes its founding ideals progressively more real. He reiterated that belief again, saying, “The long sweep of America has been defined by forward motion, a constant widening of our founding creed to embrace all, and not just some.”

Obama has warned before that progress is not assured or continuous, that two steps forward are often followed by a step back. The stark warning he offered in his farewell address went far beyond such cautions. He told his country that its cherished Constitution was useless, a scrap of paper, without a vigorous defense of its ideals. And as this wise and thoughtful leader left the stage, to be followed soon by an impulsive, bullying man-child, the implications of that warning seemed to linger. To watch Obama walk away into the darkness was an unnerving sight.