News for hackers. Stuff that matters.
Re:How the TypeScript Compiler Compiles by huydotnet on Tuesday April 12, 2022 @12:02PM (#31004444)
Hey, I'm the author of the article. Thank you so much for the feedback!

Yeah, look like I get the relation between Emitter and Type Checker in the reversed way [1] :D The type checker should provide an EmitResolver. I'll update the post and the diagram!

[1]: https://basarat.gitbook.io/typescript/overview/checker#assoc...

Re:How the TypeScript Compiler Compiles by evmar on Tuesday April 12, 2022 @12:51PM (#31005159)
The article is great, sorry for the quibble!

The maybe too subtle point I was trying to make is that, even though the TypeChecker object literally provides an EmitResolver (I think? something like that?), in terms of the conceptual layout of the compiler, if you have a box labelled "Type Checker" it's natural for the reader to think it's where type checking happens.

In other words, the graph is something like

    TypeChecker object -> EmitResolver -> js files
      |
      v
     type checking