I Spent 2 Weeks Adding Go’s Defer to TypeScript. Here’s What Happened.
I hacked the TypeScript compiler to add Go’s defer statement. The result? A cleaner, less error-prone way to handle resource cleanup. The real insight isn’t about syntax—it’s about shifting the burden of correctness from the developer’s mental model to the compiler’s AST.