Ben Affleck called out Bill Maher over his “gross, racist, disgusting” ideas about Islam during a heated debate on the presenter’s Real Time show on Friday night. Affleck took time out of promoting his latest movie Gone Girl to appear alongside author Sam Harris, former chair of the Republican National Committee Michael Steele and Nicholas Kristof.

Ben AffleckBen Affleck at the Gone Girl premiere

Maher set out his stall early, telling Harris, "You and I have been trying to make the case that liberals need to stand up for liberal principles," Maher said to fellow panelist, author Sam Harris. “Freedom of speech, freedom to practice any religion you want without fear of violence, freedom to leave a religion, equality for women, equality for minorities, including homosexuals, these are liberal principles that liberals applaud for,” Maher continued, “…but then when you say in the Muslim world this is what's lacking, then they get upset.”

“Liberals have failed us,” Harris added before Affleck sarcastically shot back, “Thank God you're here…Are you the person that understands the officially codified doctrine of Islam?”

More: David Fincher's 'Gone Girl' has 100% on Rotten Tomatoes

Ultimately, Affleck was quite reasonably arguing that radical Islamists are not the majority of Muslim views, “it's gross, it's racist, it's disgusting,” he said of Maher and Harris’s remarks. "That's an ugly thing to say," Affleck added, “How about the more than a billion people, who aren't fanatical, who don't punish women, who just want to go to school, have some sandwiches, pray five times a day, and don't do any of the things that you're saying all Muslims do.”

"What is your solution?" Affleck probed Maher and Harris. "Just condemn Islam? We've killed more Muslims than they've killed us by an awful lot." Affleck, whose movie Gone Girl topped the box-office this past weekend, has been rumoured to be considering a run for senate for several years.

More: At least Adam West thinks Ben Affleck will be a good Batman

Watch Ben Affleck in the 'Gone Girl' trailer: