ts-rust Ports TypeScript 7’s Compiler to Rust and Passes 181,711 Tests

GitHub repository preview for ts-rust, the experimental Rust port of the TypeScript 7 compiler, formatted as the story cover.

An experimental project called ts-rust has ported Microsoft’s TypeScript 7 compiler, checker, and language-server core from Go to Rust—and the project says all 181,711 ported upstream tests now pass. The repository is explicitly experimental, but it is already interesting for two reasons: it reports roughly half the type-checking time of Microsoft’s Go implementation across a 60-project benchmark, and the author says most of the port was produced through long-running AI coding-agent loops rather than a conventional hand rewrite.

This is not an official Microsoft TypeScript release. It is a third-party compatibility project pinned to a TypeScript 7.1 development revision. The right way to read the result is not “Rust replaced TypeScript.” It is that modern coding agents are now being tested against infrastructure-scale software where compatibility is measurable against an enormous existing test suite.

Microsoft Developer — Anders Hejlsberg explains TypeScript 7’s official native Go compiler, the implementation that ts-rust is attempting to match.

What ts-rust Actually Is

The project’s GitHub repository describes ts-rust, also published as tsc-rs, as a direct Rust port of Microsoft’s native TypeScript compiler. It preserves the Go implementation’s algorithms and behavior while exposing the familiar tsc-style command line, compiler API, and language-server behavior.

npm install -D tsc-rs
npx tsc-rs -p tsconfig.json

The project is currently pinned to Microsoft TypeScript revision 673a5f17d713, corresponding to a September 29, 2026 TypeScript 7.1 development build. That matters because compatibility has to be compared against that exact upstream revision rather than a different TypeScript release.

The Test Count Is the Most Important Claim

The strongest evidence in the repository is not a synthetic benchmark. It is the compatibility suite. The author says all 181,711 ported Go tests pass, and that real projects such as TanStack Query core and Hono produce diagnostics identical to the pinned Go compiler.

The language-server and API outputs are also compared against oracle test sets. That does not prove the Rust port is production-ready, but it is much stronger evidence than simply compiling itself or passing a small demo project.

This test-driven approach is especially interesting in light of BitcoinVersus.Tech’s earlier report on GitHub rewriting a 430,000-line TypeScript runtime in Rust with AI agents. In both cases, the software-development question is becoming less about whether an agent can emit Rust and more about whether the resulting system can satisfy a large machine-verifiable specification.

A current developer discussion on the project captures both sides of the reaction: excitement about the port and skepticism about maintainability when so much code is machine-generated.

The Project Claims About Half the Go Type-Checking Time

According to the repository’s own benchmark results, ts-rust type-checks a set of 60 open-source projects in roughly half the time of the corresponding Go implementation on a geometric-mean basis. That is a project-reported result, not an independent benchmark, and the release packages are not yet fully optimized with techniques such as profile-guided optimization and BOLT.

Microsoft’s official TypeScript 7 release already represented a massive performance jump over the older JavaScript/TypeScript compiler. Microsoft says the native Go implementation typically improves full-build performance by roughly 8× to 12× versus TypeScript 6. ts-rust is therefore attempting to optimize an implementation that is already much faster than the original compiler.

Thapa Technical — A detailed explanation of TypeScript 7’s native compiler, including why Microsoft chose Go instead of Rust and how the new compiler architecture improves build performance.

The AI-Agent Part Is Almost as Interesting as the Compiler

The repository’s author says earlier attempts using OpenAI coding models generated more than 1.3 million lines of Rust across multiple months but stalled at roughly 84% compatibility. The author then says a fresh attempt using Anthropic’s Opus 5.5 produced a working first version in about 10 hours and continued improving over roughly two weeks.

The author reports about $24,047 in API-priced spend for the final successful run. That number is useful mainly as a reminder that “AI wrote it” does not mean “software appeared for free.” Large autonomous coding experiments can consume significant compute, repeated tests, tool calls, repository operations, and human supervision even when the human is not manually writing every function.

This Is Still an Early Release

The repository itself is unusually blunt about its limitations. The author warns that the project is early, says the code has not been manually reviewed line-by-line by the project creator, and notes that several editor-facing language-service features are still missing.

Quick fixes, refactors, hover information, and completions are among the features not yet ported. Current published platform support is also narrower than a mature compiler toolchain: Linux x64 and macOS arm64 are available, while Windows and Linux arm64 were not yet supported in the project’s current release documentation.

That distinction matters because compiler correctness is not only about whether valid code passes. A production toolchain has to preserve diagnostics, editor behavior, project references, module resolution, build modes, incremental behavior, plugins, language-server semantics, operating-system support, and years of edge cases.

Why Rust?

Rust offers native-code performance, memory safety without garbage collection, strong concurrency primitives, and a large ecosystem for systems tooling. Those characteristics make it attractive for compilers and developer infrastructure, especially where predictable latency and memory behavior matter.

But language choice alone does not guarantee speed. The architecture, algorithms, memory layout, parallelism strategy, string representation, allocator behavior, and build profile matter just as much. In fact, developers examining ts-rust have already pointed out that preserving Go-like semantics inside Rust can introduce its own overhead.

BitcoinVersus.Tech recently covered Rust 1.99, including compiler and Cargo changes aimed at making Rust more useful in systems and CI-heavy environments. A TypeScript compiler port is another example of Rust increasingly showing up behind tools that developers use rather than only inside end-user applications.

The Bigger Question Is Maintainability

Passing 181,711 tests is impressive. Maintaining compatibility as upstream TypeScript changes every week is a different problem. A compiler is not a one-time artifact; it is a living codebase that needs debugging, security review, performance work, portability, release engineering, and developers who understand why the implementation behaves the way it does.

That is where the project becomes a useful experiment even if tsc-rs never becomes the dominant compiler. If AI agents can repeatedly port large systems and satisfy giant compatibility suites, software teams may start treating tests and executable specifications as even more important assets than the implementation language itself.

What Developers Should Watch Next

  • Upstream tracking: how quickly ts-rust can follow new TypeScript revisions.
  • Windows support: whether the project can become portable enough for normal enterprise TypeScript workflows.
  • Language-service parity: whether missing editor features reach compatibility with Microsoft’s implementation.
  • Independent benchmarks: whether other developers reproduce the project’s reported speed advantage over Go.
  • Code review: whether maintainers can understand, simplify, and safely evolve the agent-generated Rust.
  • Upstream ideas: whether any implementation techniques eventually influence Microsoft’s official compiler.

The Compiler Story Is Becoming an AI Software-Engineering Story

Microsoft’s TypeScript team spent years moving a huge compiler from TypeScript to Go for native performance and parallelism. Now an independent experiment has used coding agents to port that new native implementation again—this time to Rust—and claims broad behavioral parity against a six-figure test corpus.

The interesting part is not that Rust “beat” Go or that AI “replaced” compiler engineers. Neither conclusion follows from one experimental repository. The important signal is that large software ports are becoming testable agent workloads. The test suite is increasingly becoming the contract, while humans decide whether the generated implementation is trustworthy enough to maintain.

Editor’s Note

The 1200×630 featured image is the actual GitHub repository preview for pingdotgg/ts-rust, formatted without unrelated stock artwork. The two YouTube videos directly explain TypeScript 7’s native compiler architecture and the Go-versus-Rust design context. The Reddit embed is a current developer discussion specifically about this ts-rust project. Performance, compatibility, cost, and development-history claims attributed to the project are identified as self-reported where appropriate.

Support and donation options are available through BitcoinVersus.Tech.

BitcoinVersus.Tech is not a financial advisor. Content is provided for informational and educational purposes.

Leave a comment