Live data from Hacker News

A 10x Faster TypeScript

devblogs.microsoft.com

271–280 of 943 posts

Re: A 10x Faster TypeScript

#271
post #223

Earlier quoted context omitted.

I find the discussion about the choice quite interesting, and many points are very convincing (like the GC one). But I am a bit confused about the comparison between Go and C#. Both should meet most of the criteria like GC, control over memory layout/allocation and good support for concurrency. I'm curious what the weaknesses of C# for this particular use case were that lead to the decision for Go.

C# is fine. But last I checked, the AOT compilation generates a bunch of .dll files, which are not suitable for a CLI program like Go's zero dependencies binary.

You can choose how the linking process is done, just like you can chose to have a a Go binary with dependencies.

Re: A 10x Faster TypeScript

#273

[flagged]

This is not accusatory, but do you write your comments with AI? I checked your profile and someone else had the same question a few days ago. It's the persistent structure of "it isn't X – it's Y" with the em dash (– not -) that makes me wonder this. Nothing to add to your comment otherwise, sorry.

Sorry for being pedantic but they are using an en dash (–) not an em dash (—) which is a little strange because the latter is usually the one meant for adding information in secondary sentences—like commas and and parentheses. In addition, in most styles, you're not supposed to add spaces around it.

So, I don't think the comment is AI-generated for this reason.

Re: A 10x Faster TypeScript

#274

[flagged]

This is not accusatory, but do you write your comments with AI? I checked your profile and someone else had the same question a few days ago. It's the persistent structure of "it isn't X – it's Y" with the em dash (– not -) that makes me wonder this. Nothing to add to your comment otherwise, sorry.

em-dash is shift-option-hyphen on macOS, so it's not a good heuristic—I use it myself.

They're using en-dash which is even easier: option-hyphen.

This is the wrong way to do AI detection. For one, LLM would have used the right dash. But at least find someone wasting our time with belabored or overwrought text that doesn't even interact with anything.

Re: A 10x Faster TypeScript

#275

Dumb question: is this a 10x speed up in the run-time of TypeScript ... or just the build tooling? And if it's run-time, can we expect browsers to replace V8 with this Go library? (I realize this is a noob/naive question - apologies)

This is specifically about the performance of the TypeScript toolchain (compiler, editor experience); the runtime code generated is the same. TypeScript is just JS with types.

Re: A 10x Faster TypeScript

#276
post #145

Earlier quoted context omitted.

.NET has AOT compilation now. There really is no excuse, especially when you consider that C# has a pretty decent type system and Go has an ad-hoc, informally specified, bug-ridden, slow implementation of half of a decent type system.

> Go has an ad-hoc, informally specified, bug-ridden, slow implementation of half of a decent type system. It's not lost on me that this is a widely used aphorism. The problem is that it's not true in any way shape or form.

It absolutely is... Go's type system is an abomination.

Re: A 10x Faster TypeScript

#277
My read on why Go and not AOT C# is it would be more difficult to get a C# programmers to give up idiomatic OOP in C# than it would be to get C# programmers to switch to Go. Go is being used as a forcing function to push dev cultural change. This wouldn't generalize to teams that have other ways of dealing with cultural change.

Re: A 10x Faster TypeScript

#278

Hi folks, Daniel Rosenwasser from the TypeScript team here. We're obviously very excited to announce this! RyanCavanaugh (our dev lead) and I are around to answer any quick questions you might have. You can also tune in to the Discord AMA mentioned in the blog this upcoming Thursday.

Well-optimized JavaScript can get to within about 1.5x the performance of C++ - something we have experience with having developed a full game engine in JavaScript [1]. Why is the TypeScript team moving to an entirely different technology instead of working on optimizing the existing TS/JS codebase? [1] https://www.construct.net/en

Are you comparing perfectly written JS to poorly written C++?

Re: A 10x Faster TypeScript

#279

[flagged]

> The Go choice over Rust/C# reveals something deeper: Microsoft prioritized shipping a working solution over language politics. Go's simplicity (compared to Rust) and deployment model (compared to C#) won the day. I'm not sure that this is particularly accurate for the Rust case. The goal of this project was to perform a 1:1 port from TypeScript to a faster language. The existing codebase assumes a garbage collector…

I can't imagine the devs at Microsoft have any issues with C#'s "deployment model."

Re: A 10x Faster TypeScript

#280
Oh man, this is great. I've been having performance issues with TSC for language services.

My theory - that Go will always be the choice for things like this when ease, simplicity, and good (but not absolute) performance is the goal - continues to hold.

Post reply on HN