Working on a C# Source generator for non nullable properties. It generates partial properties which throw an ArgumentNullException when the value is set to null.
Would you use this?
#csharp14 #dotnet #sourcegenerator
Latest posts tagged with #sourcegenerator on Bluesky
Working on a C# Source generator for non nullable properties. It generates partial properties which throw an ArgumentNullException when the value is set to null.
Would you use this?
#csharp14 #dotnet #sourcegenerator
`DiagnosticSuppressor` shines, when we want a dynamic behavior for enabling/disabling a `DiagnosticAnalyzer`. Here I am covering them and of course with tests 😉
👉🏼 bit.ly/4p8d99a or scan the QR code!
#Roslyn #DiagnosticAnalyzer #DiagnosticSuppressor #SourceGenerator #csharp #dotnet
In #Unity, sometimes, general types can't convey the intention and #typesafety must be enforced, using alias directives is not the answer. We need #type wrappers. But declaring them is boringly repetitive. Why don't delegate that to a #roslyn #sourcegenerator?
github.com/laicasaane/T...
Learn how to streamline your code by removing 1500 lines of boilerplate with a custom source generator. Optimize your projects, enhance readability, and boost performance. #CodeOptimization #SourceGenerator
Just published static view locator source generator for Avalonia so you don't have to use reflection anymore #Avalonia #dotnet #charp #xaml #sourcegenerator www.nuget.org/packages/Sta...
I just published my first C# Source Generator. It generates the >, >=, <, <= operators for a partial type (class, struct or record) which implements IComparable<T>.
#dotnet #csharp #sourcegenerator #opensource
github.com/sonnemaf/Ref...
Suppress or enforce? In C#, you can silence warnings OR make sure critical ones can’t be ignored! Learn how to configure diagnostics and take control of your code analysis. ⚡
📚👉🏼 https://bit.ly/4bVU7gJ
#CSharp #Roslyn #CodeAnalysis #SourceGenerator #dotnet
I released v3 of my #dotnet #telemetry #sourcegenerator last week - a big release, and a bit of a passion project for me.
#opentelemetry
github.com/purview-dev/...
As a software engineer, just ranting about a wrong approach in a given context is not enough, we should provide options and alternatives! It applies to #diagnostic #analyzers, they should not just make noise, but providing #code #suggestion!
bit.ly/41eh0ay
#sourcegenerator #csharp #dotnet
This library is a C# source generator designed to automatically generate string length constants from Entity Framework configurations and data annotations.
#sourcegenerator #entityframework #stringlength #dotnet
github.com/TarasKovalen...
I just started working on a #dotnet #sourcegenerator for doing dependency injection in #powershell
You can build PowerShell modules in dotnet, but if you do, you are currently faced with these issues:
- no async code
- no dependency injection
- no cancellation token (but still cancelable process)
Need testable or just simplified observability in your apps and services?
ActivitySources, Logs and Metrics, all defined quickly and easily on interfaces, injectablable and easy!
github.com/purview-dev/...
#oss #observability #dotnet #opensource #sourcegenerator
Bis eben noch an meinem #SourceGenerator geschrieben (mit der Roslyn-Sache da)... Holy moly, also war 'n wilder Trip, insb. wenn man mit der #Roslyn-API arbeitet, statt 'n StringBuilder zu nehmen. Kein Wunder, dass man recht wenig Projekte damit gesehen hat und die Leute lieber Quick&Dirty machen.
A major version update has just been launched for the NetFabric.CodeAnalysis and NetFabric.Reflection packages. Additionally, a new GitHub pages site has been created for documentation purposes.
github.com/NetFabric/Ne... #dotnet #reflection #roslyn #roslynanalyzer #sourcegenerator