Episode 15: C#9 Source Generators with Jason Bock
In this episode, I was joined by Jason Bock to chat about the new C#9 source generators! Writing code that writes code! We covered a ton of content, covering Source Generators, the Compiler API, Syntax Trees, Semantic Models, Expression Trees, and much much more!
Links from the show
Jason’s Links
Jason’s books
Other links from the show
- Listener mention tweet from Nick Kirby (update: and the app he wrote is also now available!)
- Guitar photo of us both tweet (and the similar mentioned DDD episode tweet)
- Rocks
- PartiallyApplied
- SourceGeneratorDemos
- InlineMapping
- Scribian templating library
- Pex / IntelliTest
- Mutation testing lightning talk with Stefan Pölz
- Andrew Lock’s post about using source generators to find all routable components in a Blazor WebAssembly app
- Adventures in .NET podcast episode with Jason on C#9
- Benchmark.NET
References
- Introducing C# Source Generators
- Generating Code in C#
- New C# Source Generator Samples
- Source Generators Cookbook
- C# Source Generators - Write Code that Writes Code
- Source Generators in .NET 5 with ReSharper
- .NET 5 Source Generators - MediatR - CQRS - OMG!
- A list of C# Source Generators
- Using C# Source Generators to create an external DSL
- Persisting output files from source generators
- Getting started with the roslyn APIs: Writing code with code
- C# 9 records as strongly-typed ids - Part 5: final bits and conclusion
- Consider using a source generator to generate scoped css files #30841
- C# Source Generators