Since Donald Trump’s victory in the presidential election last week, Boston Mayor Marty Walsh has repeatedly vowed to protect the city’s immigrants — but he's also avoided using the phrase “sanctuary city.” Instead, Walsh has called Boston a “welcoming city," an "open city," and a “ city of inclusion.”

Here’s the catch: A law called the  Boston Trust Act is already on the books. It was written by City Councilor Josh Zakim, passed by the city council two years ago and signed into law by Walsh.

The act says Boston won’t comply with detention requests from federal immigration authorities unless they’re accompanied by a criminal warrant. “In basic terms,” Zakim says, “it prohibits the Boston Police Department from detaining people based on their immigration status.”

On Tuesday, City Council President Michelle Wu tweeted that because of the Trust Act, Boston “already has sanctuary city protections.”

For his part, Zakim isn't eager to use the “sanctuary city” phrase in connection with his legislation — though he says he's open to others doing so. “The legal standard is, our police department won’t be enforcing federal immigration laws,” Zakim says. “If someone wants to say we’re a sanctuary city, I’m fine with that."

Judging from his avoidance of the term, Walsh may not be. But the mayor’s rhetoric could also be strategic. After all, Trump has vowed to pull funding from “sanctuary cities” specifically — not “welcoming cities” or “cities of inclusion.” Wrap the same policies in different words and the Trump Administration might look the other way.

In Somerville, meanwhile, Mayor Joe Curtatone is embracing that city’s sanctuary-city designation.

Somerville first called itself a sanctuary city in 1987, during the Reagan presidency, in a city council resolution that vowed to treat all residents the same regardless of their legal status. Today, the city’s policy on immigration detention is similar to Boston’s: It won’t comply with detention requests from federal authorities unless they have a criminal warrant or the individual in question has a serious criminal history.

Asked if he might rethink Somerville’s label to lessen the chances of a confrontation with the Trump Administration, Curtatone's reply is an unequivocal no. “We’re not going to change who we are,” he says. “And I find it offensive to even think federal funding would be held over our head as a Sword of Damocles to try to buckle a community and a society to its knees to run away from our basic democratic principles and values. That's not what America is. We're not made that way."

That defiance could come with a cost. If the Trump Administration did pull federal funding, Curtatone estimates Somerville could lose about $6 million annually, or about 2.7 percent of its proposed budget for fiscal year 2017 — including funding for school lunches and homeland security programs.