The US president has vowed to "devastate" Turkey's economy if it attacks Kurdish fighters in Syria.