How it works...

Roslyn is open source, like the TypeScript compiler. One of the reasons to have our compiler written in the same language we analyze and compile, to have the benefits of the .NET Framework; for example, using lambdas and LINQ in the immediate window. Another advantage is to see all the compiler code with a tool like ILSpy.

We will now have access to all stages of our compiler through an API, which allows us to manipulate an object model representing the source code we are analyzing as a Syntax Tree. Through these APIs, we will have access to a rich set of language services we can integrate to editors.

Get ASP.NET Core MVC 2.0 Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.