15
Roslyn Compiler Extensions
Roslyn compiler extensions offer a powerful way to modify and extend the behavior of the C# compiler. With the Roslyn compiler, developers can write code that analyzes and modifies C# code at compile-time, opening new possibilities for code generation, code transformation, and optimization.
In this chapter, we will explore the technical setup of a Roslyn compiler extension project. The chapter itself is not focused on metaprogramming, but rather, on the technical setup for the two following chapters. We’ll delve into the process of packaging a Roslyn compiler extension for reuse. We’ll explore the different packaging options available, such as NuGet packages, and discuss best practices for making your extension ...
Get Metaprogramming in C# 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.