The history of C# and TypeScript with Anders Hejlsberg | GitHub

By GitHub

Share:

Key Concepts

  • Turbo Pascal: A pioneering integrated development environment (IDE) emphasizing rapid compilation and execution, revolutionizing the developer experience in the 1980s.
  • Deli: Anders Hejlsberg’s subsequent project, marking a transition to team leadership and addressing the increasing complexity of software development.
  • C# & .NET: A platform and language designed to combine the ease of use of Visual Basic with the power of C++, focusing on interoperability and maximizing platform advantages.
  • TypeScript: A superset of JavaScript designed to address scalability and tooling challenges in large JavaScript applications, prioritizing developer experience and open-source collaboration.
  • Self-Hosting: The practice of a compiler being written in the language it compiles, offering advantages but also limitations in performance and scalability.
  • AI-Assisted Coding: The emerging trend of leveraging artificial intelligence to automate coding tasks, improve developer productivity, and address code maintenance challenges.
  • Open Source Sustainability: The ongoing challenge of funding and maintaining open-source projects, balancing community contributions with commercial interests.

The Evolution of a Programming Language Pioneer: A Conversation with Anders Hejlsberg

This conversation with Anders Hejlsberg, a highly influential programming language designer, traces his career from early computing experiences to the development of Turbo Pascal, Deli, C#, and ultimately, TypeScript. The discussion delves into the philosophies behind his design choices, the challenges of scaling development efforts, and the impact of artificial intelligence on the future of programming.

Early Computing & Turbo Pascal: The Pursuit of Speed and Accessibility

Hejlsberg’s initial exposure to computing came in high school, leading to a fascination with building and programming his own kit computer in the late 1970s. He emphasized the constraints of early systems – 64K of memory required careful resource management – but also the joy of direct control through assembly and structured programming. This experience shaped his focus on developer productivity.

Turbo Pascal emerged as a response to the limitations of BASIC interpreters, which, while offering a quick development cycle, suffered from slow execution speeds and a rudimentary editing experience. Hejlsberg’s key innovation was a fast compiler that compiled directly to memory upon execution ("run"), providing an incredibly interactive experience. He described the compiler as “primitive” but effective, allowing developers to quickly identify and address errors. The affordability of Turbo Pascal, priced at $49.95, was a deliberate strategy by Borland to maximize reach, selling orders of magnitude more copies than its predecessor, Poly Pascal.

Scaling Development: From Solo Creator to Team Leader (Deli)

The success of Turbo Pascal necessitated a shift from Hejlsberg’s initial “one-man show” to a collaborative team approach with Deli. He acknowledged the challenges of relinquishing control and accepting code that didn’t perfectly align with his preferences. However, he stressed the importance of empowering team members and delegating responsibility as essential for scaling development efforts. He noted that focusing on core functionality and accepting “good enough” code was crucial when time was limited.

C# and .NET: Pragmatism and Platform Integration

Hejlsberg’s work at Microsoft, beginning in 1996, focused on Java development tools. He quickly identified the limitations of the initial Visual J++ implementation and the broader Java philosophy of “write once, run everywhere.” He argued that for the Microsoft platform, prioritizing interoperability with Windows and delivering the best possible user experience was paramount. This led to the development of C# and the .NET platform, aiming to combine the ease of use of Visual Basic with the power and expressiveness of C++. He emphasized a holistic view of the development experience, encompassing the runtime, compiler, class library, and tooling. He stated, “Users don’t care whether this is a language feature or a framework feature… it’s the whole thing is the experience.”

TypeScript: Addressing JavaScript’s Scalability Challenges

The conversation then turned to TypeScript, born from observing the challenges faced by developers building large-scale applications with JavaScript. The emergence of faster JavaScript runtimes (like V8) and improved UI technologies (HTML5) led to increasingly complex JavaScript projects. Hejlsberg recounted the story of the Outlook.com team using “Script Sharp” – a C++-to-JavaScript translator – to address tooling limitations. This sparked the idea of improving JavaScript itself rather than relying on translation.

The key design decision was to make TypeScript a strict superset of JavaScript, allowing developers to gradually adopt the language without a disruptive migration. Hejlsberg articulated the rationale: “We’re not going to create a whole new language… we’re just going to fix what’s broken about it.” This approach minimized the barrier to entry and leveraged existing JavaScript tooling. He emphasized the importance of “meeting developers where they are.”

Open Source and Community Engagement

The decision to release TypeScript as an open-source project on GitHub in 2014 (after an initial release on CodePlex) was a pivotal moment. Hejlsberg acknowledged the initial resistance within Microsoft but stressed the necessity of embracing open-source principles to engage with the JavaScript community. He highlighted the benefits of open development, including increased transparency, community contributions, and a more collaborative development process. He described the shift from “throwing code over the fence” to a fully integrated open-source workflow as a “win-win” for both developers and users. He noted the importance of trust and actively participating in the community.

The TypeScript Compiler Port to Go: Performance and Scalability

Hejlsberg detailed the recent decision to port the TypeScript compiler to Go, driven by performance and scalability concerns. While TypeScript’s self-hosting model offered advantages, it ultimately reached its limits in handling increasingly large codebases. Go offered the benefits of native code execution and shared memory concurrency, resulting in a 10x performance improvement. He emphasized the importance of maintaining functional compatibility with the existing JavaScript-based compiler to avoid disrupting the developer experience. He stated, “You can’t just ignore 10x. Do you know what I mean? God damn. That changes everything.”

The Future of Programming with AI

Hejlsberg discussed the transformative potential of AI-assisted coding. He believes AI excels at automating repetitive tasks and addressing code maintenance challenges, freeing developers to focus on higher-level problem-solving. He cautioned against creating entirely new languages specifically for AI, arguing that AI’s capabilities are directly proportional to the amount of code it has been trained on. He envisions AI taking on more of the “housekeeping” tasks in software development, such as issue ranking and code cleanup. He also acknowledged the potential disruption to the programming workforce and the need to find ways to nurture junior developers into senior roles.

Looking Ahead: TypeScript in an AI-Native World

Hejlsberg anticipates that TypeScript’s evolution will be driven by the standardization of JavaScript and the addition of necessary type system features. However, he believes the most significant changes will occur in tooling, with AI playing an increasingly prominent role in code completion, refactoring, and debugging. He emphasized the need for a balance between traditional IDE-based tools and AI-powered agents.

Final Thoughts: Open Source and Respect for Existing Languages

Hejlsberg concluded by reflecting on the challenges and rewards of open-source development, acknowledging the ongoing need to find sustainable funding models. He expressed respect for other programming languages, recognizing that any language that achieves relevance has inherent value. He emphasized the importance of learning from the successes and failures of others and standing “on the shoulders of giants.” He ended on an optimistic note, expressing his belief in the continued growth and evolution of open-source software.

This conversation provides a valuable insight into the mind of a programming language pioneer, highlighting the importance of developer experience, pragmatic design choices, and the power of community collaboration. It also offers a glimpse into the future of software development, where artificial intelligence will play an increasingly central role.

Chat with this Video

AI-Powered

Hi! I can answer questions about this video "The history of C# and TypeScript with Anders Hejlsberg | GitHub". What would you like to know?

Chat is based on the transcript of this video and may not be 100% accurate.

Related Videos

Ready to summarize another video?

Summarize YouTube Video