Paul Ryan is right—and Paul Ryan is wrong. So very wrong.

The most influential Republican in Washington recognizes that the presumptive nominee of his party is preaching racist dogma on the campaign trail. The speaker of the House decries Donald Trump’s claim that a federal judge is not qualified to preside over a case involving the billionaire Republican—who has bashed Mexicans throughout his campaign—because the jurist’s “Mexican heritage” creates a conflict of interest.

“I regret those comments he made,” Ryan said Tuesday, when asked about Trump. “Claiming a person can’t do their job because of their race is sort of like the textbook definition of a racist comment. I think that should be absolutely disavowed. It’s absolutely unacceptable.”

But, says Ryan, he is still on the Trump train, affirming his role as perhaps the most prominent endorser of a candidate who spouts what Ryan himself describes as “absolutely unacceptable” rhetoric that “should be absolutely disavowed.”

Ryan’s stance is absolutely absurd.

Trump’s attacks on US District Judge Gonzalo Curiel, who is presiding over a case involving allegations that Trump University defrauded people who signed up for courses, match most definitions of a racist comment. And Trump has not dialed down his incendiary language. He has amplified it, even going so far as to weigh the prospect that Muslim jurists should be barred from cases involving him, as the billionaire has spent much of the past year ranting and raving about followers of Islam. So Trump’s remarks were not a slip of the tongue. His stance is not a mistake that he could casually correct; this is a focus of his campaign, which he has brought up at rallies and ordered his supporters to defend. Trump is running a campaign that has repeatedly been criticized for promoting and perpetuating racial bias.

Ryan recognizes that bias. But nonetheless, on Tuesday, Ryan reaffirmed his endorsement of the presumptive nominee, which he made only last week, as Trump was ramping up his attacks on Judge Curiel, an Indiana-born jurist of Mexican-American descent. “I believe that we have more common ground on the policy issues of the day, and we have more likelihood of getting our policies enacted with him than we do with [Democrat Hillary Clinton],” said Ryan.

No one doubts that Ryan disagrees with Clinton on a host of issues. But responsible Republicans have in the past rejected party nominees who they felt were insensitive or irresponsible when it came to addressing the racial divide in this country. When Barry Goldwater voted against the Civil Rights Act of 1964, some of the most prominent Republicans in the country determined that they could not support him as their party’s nominee in that year’s election. Goldwater, who historians suggest was a more honorable man than Trump, said he opposed civil-rights legislation because of his general concern about federal intervention in the states. But Goldwater’s position was too extreme for responsible Republicans, who were deeply troubled as their party’s nominee collected the support of Southern segregationists. The Republican attorney general of Massachusetts, Edward Brooke, who two years later would be the first African American elected to the US Senate since Reconstruction, announced that he could not support Goldwater. So, too, did Republican Congressman John Lindsay, who a year later would be elected mayor of New York City. Backing Goldwater, said Lindsay, would represent a “retreat from principle” and “the historic Republican party principles that I represent.”

And what of Paul Ryan today? Ryan recognizes racism—“the textbook definition of a racist comment”—in a Republican candidate’s remarks. But he will not reject that candidate because he thinks it would be harder to enact his policy agenda with a Democrat in the White House.

Ryan is profoundly wrong about this. He is placing partisanship ahead of opposing what he himself identifies as “textbook” racism that “should be absolutely disavowed.” That’s shameful on any level. But it is particularly shameful coming from the congressional leader of a Republican Party that was once led by a president who signed an Emancipation Proclamation and longed for the day when this union would be guided “by the better angels of our nature.”