President Donald Trump’s threat to close the southern border was met with criticism and concern from politicians, activists, the public—and Pope Francis. 

Trump is taking the action, he said, because of what he believes is a crisis in drug smuggling and human trafficking.

In remarks to reporters Sunday on the papal plane en route from Morocco to Rome, Pope Francis said that Trump—and people who think the way the U.S. president does about migrants—are ultimately trapping themselves in an inhumane situation. 

“Builders of walls, be they made of razor wire or bricks, will end up becoming prisoners of the walls they build,” the pope said. 

The comments preceded a tweet made by the pope Saturday in which he celebrated the rights of migrants to self-determination.

“Every human being has the right to life, to dream and to find his or her rightful place in our ‘common home!'” posted the pontiff. “Every person has a right to the future.”