adding a clone of TypeScript df3567c7, plus some modifications, as a test case for Safe TypeScript