NASHVILLE, Tenn. — President Donald Trump on Tuesday slammed frequent foe Sen. John McCain, R-Ariz., who is battling brain cancer, for having voted against a measure that would have repealed Obamacare last year.

Speaking at a rally here, and without directly naming McCain, Trump said his efforts to scrap President Barack Obama's signature health care law were frustrated by the Arizona senator's decision to give a thumbs-down to the bill on the Senate floor in July.

"We had it done folks, it was done, and then early in the morning somebody turned their hand in the wrong direction," Trump said. "The person that voted that way only talked repeal and replace. He campaigned on it."

The rhetorical jabs were Trump's first public comments about McCain since it was reported this month that White House press aide Kelly Sadler had privately told colleagues there was no reason to worry about the senator's antipathy toward a Trump nominee because McCain is "dying anyway." That remark infuriated lawmakers, including many of McCain's fellow Republican senators, but Trump has shown more concern about the leaking of the conversation than about the disrespect shown to McCain.

Sadler remains in her job.

There's no love lost between McCain and Trump — McCain allies have told the White House that Trump is not welcome at the senator's funeral — but Trump had not attacked McCain for some time before Tuesday night. Their feud dates back at least as long as the early days of Trump's 2015 presidential campaign, when McCain called Trump supporters "crazies" and Trump questioned McCain's valor in Vietnam.

Back then, Trump called McCain a "loser" and ridiculed him for the years he spent in a Vietnamese prison camp after his plane was shot down.

"He is a war hero because he was captured," Trump said. "I like people who weren't captured."

On Tuesday, McCain wasn't Trump's only target in a speech delivered just hours after he and his aides vowed that he would be focused singularly on public policy and not on distracting side fights.

He ripped hip-hop star Jay-Z for using profanity, including the "F" word, at a rally for Hillary Clinton in 2016.

"His language was so filthy that it made me like the most clean-cut" person in the world, Trump said.

And he went back to a favorite recent talking point, calling House Minority Nancy Pelosi an "MS-13-lover" because she objected to his use of the word "animals" to describe some undocumented immigrants. Trump, who was responding to a statement about MS-13 when he used the word, later said that he was referring specifically to the gang.

On Tuesday night, he asked his audience to tell him the word that he had used.

"Animals!" the audience at the modest municipal auditorium here shouted in unison.

But Trump steered clear of the biggest cultural controversy of the day, ignoring ABC's decision to cancel the television show "Roseanne" because star Roseanne Barr wrote on Twitter Monday if "muslim brotherhood & planet of the apes had a baby” it would be Valerie Jarrett.

Jarrett, one of Obama's top advisers and closest friends, is black.

Jarrett responded that Barr's latest episode was "a teachable moment" — and Trump, who seldom shies away from cultural battles, may have learned that it was best not to stick up for Barr, who has been a big supporter of his.

Trump was in town to raise money and campaign for Rep. Marsha Blackburn, who is the GOP's candidate for the Senate seat being vacated by retiring Sen. Bob Corker, R-Tenn. When Trump mentioned Corker's presence, the crowd booed lustily. But Blackburn seemed to be on good footing with the Trump backers at the rally.

They cheered when Trump praised her — "a great woman," he said — and when he let her take the microphone briefly.

And Trump took some light swings at Phil Bredesen, the two-term former governor who is the Democrats' pick to take on Blackburn.

"Phil whatever-the-hell-his-name-is," Trump said. "This guy will 100 percent vote against us every single time."

Ron Burkett, a 61-year-old home-builder from Hendersonville, said he supports Blackburn — but that she wasn't the big draw Tuesday night.

"That's not why I came here," he said before Trump took the stage.