“Justice Roberts turned out to be an absolute disaster, he turned out to be an absolute disaster because he gave us Obamacare,” Mr. Trump said in 2016, presumably referring to Chief Justice Roberts’s votes to sustain President Barack Obama’s health care law.

There is reason to think, then, that Mr. Trump’s praise of Justice Kennedy was strategic.

Then, after Justice Gorsuch’s nomination was announced, a White House official singled out two candidates for the next Supreme Court vacancy: Judge Brett M. Kavanaugh of the United States Court of Appeals for the District of Columbia Circuit and Judge Raymond M. Kethledge of the United States Court of Appeals for the Sixth Circuit, in Cincinnati.

The two judges had something in common: They had both clerked for Justice Kennedy.