Mexican Economic Minister Ildefonso Guajardo Villarreal said Wednesday he will work with Donald Trump should the Republican nominee win the presidency in November.

"We cannot afford to risk a very important bilateral agreement," Villarreal said. "If we have to talk to the devil to guarantee the safety of the Mexican people, Mexico will talk to the devil."

The Mexican leader made the statement Wednesday evening at a forum in New York that included presidents from Peru, Chile and Colombia in its panel. Villarreal stood in for Mexican President Enrique Pena Nieto who was unable to attend.