Sen. Kamala Harris has slammed presidential candidate Pete Buttigieg for comparing the struggles of African Americans to those of the LGBTQ community.

Appearing on MSNBC's Andrea Mitchell Reports, Harris said Buttigieg should have known better than to try and compare the struggles of two historically marginalized groups.

"Well, I wouldn't say I'm going after him [Buttigieg]," she said. "For those of us who have been active in the civil rights community for a long time, it's just really well-known that we don't compare struggles ... it's not productive.

"It works against what has always been the strength of the civil rights movement," she continued. "And that is the coalition building. That is the work that we do, recognizing the history and the struggle that each has...Not comparing them, but knowing that when we are unified around those things that we share in common, we are strong as a movement and that no one should be made to fight alone."

During the primary debate, Buttigieg said that he did not know what it's like to be discriminated against because of the color of his skin but said that he'd been made to feel marginalized by other Americans.

"I do not have the experience of ever having been discriminated against because of the color of my skin," he said. "I do have the experience of sometimes feeling like a stranger in my own country."

In the next debate, he tried to make it clear that he was not trying to compare the marginalized groups.

"Well, first of all, there is no equating those two experiences, and some people, by the way, live at the intersection of those experiences," he said. "What I do think is important is for each of us to reveal who we are and what motivates us. And it's important for voters to understand what makes me tick, what moves me, and my sources of motivation, ensuring that I stand up for others. And last night, I shared some of my... personal experience, my governing experience, and my personal faith."