async function f() { throw new Error("x"); } try { f(); console.log("after call"); } catch (e) { console.log("caught"); }