The war in Syria has been raging for almost eight years and has triggered unimaginable suffering, as well as a substantial reshuffling of alliances in the Middle East. Recently, the Syrian nightmare was made even more worrisome because of the abrupt decision of U.S. President Donald Trump to withdraw his forces from northeastern Syria where they are fighting the remnants of the Islamic State.

Trump’s brand of foreign policy is disconcerting even for the most seasoned observers in the Washington beltway. Short of finding a rationale for it, Trump’s latest moves on Syria seem to have been driven by at least five impulses.

First, do not listen to your sophisticated national security apparatus, even if the price is losing some of your best people, including defense secretary James Mattis on December 20 and special presidential envoy Brett McGurk on December 21.

Second, whenever possible do the exact opposite of what former president Barack Obama did.

Third, ignore your allies, such as France, who have ground troops in Syria working daily with U.S. forces against the Islamic State.

Fourth, take decisions based on populist instincts, even if it means backtracking partly in subsequent days.

Fifth, use provocative language with partners because it sells well with your electorate.

This brand of foreign policy creates multiple ripple effects on the international scene. Using the Syrian Kurdish People’s Protection Units (YPG) for years to successfully lead the fight against the Islamic State resulted in solidly holding a vast swath of Syrian territory north and east of the Euphrates River, well beyond Kurdish-majority areas. But banking mostly on Kurdish forces because they were by far the most efficient and reliable forces on the ground led to expected problems with Turkey, for which the priority is countering its own Kurdish insurgency more than fighting the Islamic State.

Whether the choice of relying on the YPG, which Ankara considers the Syrian extension of its own insurgents, the Kurdistan Workers Party, was wise is a matter of debate. But suddenly letting the YPG down has clear consequences. It pushes the Kurdish force into the arms of the Assad regime and therefore also plays into the hands of Moscow and Tehran—a paradoxical outcome for a White House that has made containment of Iran a priority.

Trump’s decision also leaves hanging the United States’ core allies in NATO, especially France and the United Kingdom. France in particular has about 200 troops on the ground, compared to some 2,000 U.S. troops. The French and the Americans operate in a closely coordinated manner and France’s contingent, by virtue of its smaller size, largely depends on its U.S. colleagues for logistics, including a French withdrawal when that time comes.

Trump’s decision also undermines the Western strategy of seeing a political settlement of the Syrian conflict negotiated within the confines of the United Nations. Holding on to about 30 percent of Syrian territory (even if it is largely empty) is significant when it comes to a settlement in the more legitimate UN framework, as compared to the opportunistic Astana framework.

One of the few ways Western countries had to influence a UN-based settlement was their continued presence on the ground. Now, Trump has given this card away without prior notice, furthering the Assad regime’s strategy of regaining control over all borders in northern Syria. Has the immense benefit of this for Iran been taken into account? Again, how does all this square with the anti-Iran stance dear to the Trump administration? Answers are left to imagination.

One of the most unexpected fallouts of the withdrawal decision is that it left Turkey out in the cold and made it much more dependent on Russia for its next moves. At first sight, Trump’s decision seemed to play into Ankara’s hands, but that was only on the surface. In reality, Turkey’s intention to invade northern Syria east of the Euphrates to divide Kurdish-held areas into three separate entities—Afrin, now occupied by Turkey with Russia’s consent, Kobani, and Qamishli—is subject to Russian authorization, which, if it is positive, will perhaps come without permission to use air cover.

In addition, having realized how detrimental to Kurdish interests his abrupt withdrawal decision was, on January 14 Trump sought to “protect” the Syrian Kurds. Typically, he tweeted that the “long overdue pullout from Syria” will go hand in hand with “hitting ... hard” the remains of the Islamic State, while Trump also threatened to “devastate Turkey economically if they hit Kurds.” In two convoluted tweets, the president managed to both please Turkey—by seeking to “create a 20-mile safe zone” and underlining that the United States did “not want the Kurds to provoke Turkey”—and outrage, by warning of unspecified economic sanctions. This haphazard policy can only fuel anti-American feelings in Turkey and push its leadership to further disconnect the country from its Western allies.

“Bringing the boys home” is a popular theme in today’s America, and Trump’s decision probably has a solid populist logic to it. But foreign policy is supposed to serve long-term strategic interests not just short-term electoral goals. Ultimately, an American policy for Syria implemented in this way hands over a massive political victory to Washington’s stated “enemies”—Russia and Iran.