The line to attend Salman Rushdie’s sold-out appearance at the UVA-sponsored “Human/Ties” festival stretched past the Paramount Theater and snaked across Charlottesville’s Downtown Mall and down a side street Friday night.

The appearance by the internationally acclaimed novelist was one of the humanities festival’s most heavily anticipated events, and he and New York University colleague Suketu Mehta entertained their audience with an hour-long conversation that hopped from their migrant roots, to how literature can help us make sense of our unlimited world, to what Rushdie jokingly called the most embarrassing fact of his life: the realization that Donald Trump thinks Rushdie is cool.

One of the most celebrated authors of his generation, the British-Indian novelist became an American citizen after two decades of living in New York City. He first gained international acclaim with his second novel, 1981’s “Midnight’s Children.” The novel won both the prestigious Booker Prize and later in 1993 a special Booker Prize as the best British novel of the past 25 years.

Rushdie and Mehta, the New York-based author of “Maximum City: Bombay Lost and Found,” discussed how their shared experience of growing up in the Indian city of Bombay (now known as Mumbai) before moving to England and the United States inform their literary work as migrants.

“We live in the age in which more people have moved across the face of the earth than ever before in the history of the world. It doesn’t even have to be international migration,” Rushdie said. “Sometimes I think that to move from a small Midwestern town to New York City is a bigger move than to move from Bombay to New York. If you’re used to living in a metropolitan environment, if you know what living in a big city is like, then it’s not that difficult to adjust to another big city.”

Rushdie and Mehta were introduced on stage by Debjani Ganguly, a professor of English and director of UVA’s Institute of Humanities and Global Cultures. Like the two writers she was introducing, Ganguly has family roots in Mumbai.

“What are the odds here, of two Bombay writers, and myself a third Bombayite, on stage together in a town called Charlottesville?” she said, opening the discussion.

That metropolitan, global perspective plays a key role in the sprawling novels of Rushdie, who frequently writes about characters rich and poor moving from one country to another for a variety of reasons. And while classic 19th-century novels such as “Madame Bovary” and “Pride and Prejudice” focused on geographically limited stories where the author assumes that he and his readership share the same perspective, Rushdie said, that model does not serve his writing. The outside world invades, and informs, the stories he tackles.

“We were both in New York during 9/11,” Rushdie said to Mehta. “And one of the things that I thought happened that day, is that what literally happened that day was the story of the Arab world smashing into the story of New York City, and that afterward you couldn’t understand the story of New York without also having some knowledge of the Arab world.

“How do you write about that? How do you write about this other world in which everything connects to everything, and that’s the question I’ve been asking myself increasingly, in book after book. And that’s the thing that migrant figures like you and me have access to, because we’ve been a part of more than one world and we know how they join up because they join up in us. So you try to turn that into an advantage.”

At the time of the second Booker Prize, Rushdie had to come out of forced seclusion to accept the award. Following the publication of his fourth novel, “The Satanic Verses,” in 1988, the spiritual leader of the Islamic Republic of Iran had issued a fatwa, or religious edict, calling for Rushdie to be put to death for writing a book deemed blasphemous and insulting toward Muslims. Despite the fatwa, Rushdie has gone on to write 12 novels, four works of nonfiction, two plays and one screenplay and has resumed a public life as an ardent freedom-of-speech advocate.

“I’ve often thought, why is it that people naturally authoritarian in their characters and in their policies are so worried about writers that they are the first people they arrest,” said Rushdie, commenting on leaders such as Russian president Vladimir Putin, Indian Prime Minister Narendra Modi and conservative French politician Marine Le Pen who clamp down on public dissent. “I think it’s because writers have a voice that nobody owns. … They want to tell the story and say, ‘The story goes like this.’ And if you decided to say, ‘No, it doesn’t. The story doesn’t go that way,’ then you are protesting the thing that is most important to them, which is to control the narrative. And that’s why they want to lock writers up.”

Rushdie included Donald Trump in this list of leaders and political figures exhibiting authoritarian tendencies, and he took several jabs at the presidential candidate in his remarks.

“I’m not entirely sure that a President Trump won’t not want to do that,” Rushdie said. “He’s already talked about wanting to limit the freedom of the press, which is an amazing thing to say in the country of the First Amendment.”

Yet, one of Rushdie’s greatest embarrassments, he said, involved bumping into Trump several years ago backstage at the Metropolitan Opera. Trump saw Rushdie as he approached him walking down the hall, and he enthusiastically pointed two index fingers at him, Rushdie said.

“He said, ‘You’re the man!’ I knew the answer to this,” Rushdie said. “I said, ‘No, Donald, you’re the man.’”

Several years later, Rushdie said, he ran into Trump again, and he offered Rushdie use of his box at the U.S. Open when he heard that Rushdie was a tennis fan.

“I thought, ‘This is a career-ending move if I’m seen in Donald Trump’s box,’” Rushdie said. “Anyway, this is my problem: Donald Trump thinks I’m cool.”

When asked his opinion on whether college campuses in the United States were becoming increasingly subject to efforts to censor controversial speech, Rushdie said he thinks the reports of students’ demands for “safe spaces” and “trigger warnings” have been overplayed. At the same time, universities should remain places where ideas can be challenged, Rushdie said to applause.

“We don’t go to college to be told what you already know. You go to college to be confronted with ideas,” Rushdie said. “And one or two of them might scare you. But that’s the point. And if you don’t want that to happen to you, maybe you should not be at a university. Maybe you should be washing dishes somewhere.”

Rushdie said that he worries that some students are willing to accept a degree of censorship in order to prevent the expression of views of which they disapprove, but historically, wherever censorship has been empowered, the first communities that suffer from that are those espousing minority points of view.

As he stressed his point about the importance of free speech, he also embedded a sly quip revealing his dismissive opinion of a certain series of bestselling series of erotic novels.

“It’s a very dangerous path for people to take to use censorship as a way of defending minorities, because it will backfire. It always has. I think we have to develop thicker skins. The point about democracy is that people say all kinds of stuff that you don’t like. There are plenty of people publishing books that I really don’t like. There’s ‘50 Shades’ of them. But I feel that those writers should be allowed to live and probably [have] no barriers to publish.”