BOSTON (CN) — Framed by a national debate on censorship of controversial viewpoints, the Supreme Court struggled at oral arguments Tuesday on where to draw the line for private speech in public spaces that the government finds inappropriate or offensive.

The case stems from three 83-foot-tall flagpoles outside Boston’s City Hall where the U.S. flag and the state flag are always flying, but the third flag is subject to temporary installations. When it was not flying the city flag, the pole bore the flags of all 284 images that citizens petitioned to celebrate for over a decade. That unbroken record in 2017, however, ended when Howard Shurtleff proposed flying a Christian flag — specifically a flag of a red Latin cross — for a ceremony to mark the signing of the U.S. Constitution on September 17, 1787.

Boston’s lawyer posed several hypotheticals at the Supreme Court on Tuesday to underscore why Shurtleff's flag didn't fly.

“No city can run the risk of being forced to fly a swastika in front of city hall,” Douglas Hallward-Driemeier of Ropes & Gray in Boston told the court.

“The city cannot afford the idea that its flagpole has become a forum for ISIS or al-Qaida,” he warned, using another name for the Islamic State group. “Or the New York Yankees.”

In recent precedent on similar issues, the Supreme Court held that, because it was the government speaking, the state of Texas could reject a specialty license plate with a Confederate flag. This 2015 ruling came six years after the court found that a city didn’t have to accept a monument in a public park proposed by the quasi-religious group Summum despite having previously allowed privately funded monuments. 

On the other hand, in 2016 the court said the federal government couldn’t reject a trademark for an Asian rock band called The Slants on the grounds that it was ethnically derogatory because it was the band and not the government that was expressing a viewpoint.

David Hudson, a professor at Belmont University College of Law in Nashville, observed in an interview with Courthouse News that the government-speech rule is “an incredibly powerful doctrine” that can “cut off First Amendment claims at their knees."

While the immediate question before the court was whether Boston had made its flagpole a public forum, a deeper question asks whether and how a government can allow a diversity of views and yet still maintain some control.

The justices struggled with the fact that the city’s flag-raising program said it was a public forum that welcomed anyone to apply, and yet a casual observer seeing a flag over City Hall would likely assume that it was the government that was conveying a message.

“What are you going to think?” asked Justice Stephen Breyer. “Three flags outside City Hall. Of course anyone in their right mind will think it has something to do with the city.”

Justice Elena Kagan agreed. “If you’re on the street and see these three flagpoles, why would you think this is anything other than the government flying a flag?”

Mathew Staver, an attorney for Shurtleff with Liberty Counsel in Orlando, Florida, appeared to make little headway with his claim that “an informed observer” would know about the city’s flag-raising program.

“Wow, that is very, very informed!” exclaimed Kagan, who for six years served as dean of the Boston-area Harvard Law School. “Not your typical person who walks the city of Boston.”

“You’re asking us to import a fiction,” added Justice Sonia Sotomayor.

Justice Amy Coney Barrett wanted to know what a government could do to invite a diversity of viewpoints but still make clear that it was the one in charge, such as having a local official be present when a flag was raised.

“A government official could participate for Juneteenth but not for the Proud Boys,” she suggested.

Justice Department attorney Sopan Joshi, argued as a friend of the court, that the city could create a “limited public forum” by opening up the program to only certain types of flags or observances. For instance, it could only allow foreign national flags to commemorate its citizens’ ethnic origins, or it could limit participation to nonprofits.

Joshi compared this to “the difference between hosting a symposium versus hosting an open-mic night.”

A recurrent theme in the argument was that the case arose by accident. A Boston official rejected the religious flag based on the assumption that flying it over City Hall would violate the Establishment Clause, which the justices agreed was not true. But rather than admit a mistake, Staver said, the city doubled down and started claiming the flagpole was government speech rather than a public forum.

If the city had originally wanted the flagpole to be government speech, “it wouldn’t have been hard to do,” said Breyer. “But they gave it no thought, like zero. Shouldn’t this case just be settled?”

The parties’ lawyers showed no signs of compromise, but Breyer’s suggestion that they agree to make the case go away proved popular with the justices.

“I had same thought as Justice Breyer. Why hasn’t this been settled?” asked Kagan.

“We all agree” that the Boston official was mistaken, said Justice Neil Gorsuch. “What is left to decide? Why doesn’t that resolve this case? Assume a public forum, and it was a misunderstanding.”

“The end,” said Kagan.

Whatever happens with this case, the larger question of government censorship of religion is unlikely to end soon.

Rick Garnett, a professor at Notre Dame Law School, authored an amicus brief cataloguing governments’ many recent efforts to squelch religious speech, including the University of Iowa deregistering religious student groups, Florida State University removing a member of the student senate for sharing religious views in text messages and a high school in Washington state that punished a football coach for praying on the field after games.

In Tampa, a transit authority refused to let a synagogue advertise “Chanukah on Ice” along a bus route. All these actions could implicate the government-speech rule and raise questions about what is and is not a public forum.

In an indication of concern about the issue, the case drew some two dozen amicus briefs ranging from a consortium of 12 states to the ACLU, the American Legion, the Anti-Defamation League and the National Council of the Churches of Christ in the USA.

A ruling is expected by June.