British Prime Minister Boris Johnson on Tuesday equated his country’s impending departure from the European Union to having one’s liver pecked out by an eagle for all of eternity.

In his address to the United Nations General Assembly Tuesday evening, Johnson used the Greek myth about the titan Prometheus to talk about the potential dangers of artificial intelligence. Zeus punishes Prometheus for stealing fire, a godlike technology, by chaining him to a mountain where his liver is pecked out by an eagle every night only to regrow during the day and be plucked out again.

BREXIT SAGA: WHAT HAPPENS NOW AFTER SUSPENSION OF UK PARLIAMENT RULED ILLEGAL?

“This went on forever,” Johnson said, recounting the tale. “A bit like the experience of Brexit in the UK, if some of our Parliamentarians have their way.”

Johnson addressed a half-empty chamber around 10 p.m. following a tumultuous day receiving criticism back home for refusing to resign after the United Kingdom’s highest court ruled that he had broken the law by advising the Queen of England to suspend Parliament amid Brexit debate.

The embattled prime minister delivered the second-to-last speech at the UN Tuesday, taking the stage to discuss the challenges and potential of new technology. Johnson said he welcomes the benefits technology has brought to society in the past but warned it is “like nuclear power - it is capable of good and bad.”

He said future tech could also be used “to keep every citizen under round the clock surveillance.” “A future Alexa will pretend to take orders, but this Alexa will be watching you” and “your mattress will monitor your nightmares,” Johnson continued. He spoke of all information being stored in a “giant dark thunder cloud” of data waiting to burst and “we have no control over when precipitation will happen.”

"At stake is whether we bequeath an Orwellian world, designed for censorship, oppression and control," Johnson said. "Or one of emancipation and learning."

"The mission of the United Kingdom and all who share our values must be to ensure that emerging technologies are designed from the outset for freedom, openness and pluralism, with the right safeguards in place to protect to our peoples.”

During his speech, Johnson also invited delegates to a summit on responsible technology in London next summer. He boasted that London has the largest tech sector in all of Europe and is “a wonderful city” where “it is not raining, 94 percent of the time.”

CLICK HERE TO GET THE FOX NEWS APP 

Johnson has been in New York since Monday. He met with world leaders Tuesday, including President Trump and Iranian president Hassan Rouhani, the Telegraph reported.