From 18cd59d414b1b25d720954e285bbd5059255a97f Mon Sep 17 00:00:00 2001 From: Alex Macocian Date: Sun, 29 Jun 2025 12:25:13 +0200 Subject: [PATCH] Mark notifypropertychanged with nullable --- .../NotifyPropertyChangedGenerator.cs | 2 +- .../SystemExtensions.NetStandard.Generators.csproj | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/SystemExtensions.NetStandard.Generators/NotifyPropertyChangedGenerator.cs b/SystemExtensions.NetStandard.Generators/NotifyPropertyChangedGenerator.cs index 78703ae..2a017b0 100644 --- a/SystemExtensions.NetStandard.Generators/NotifyPropertyChangedGenerator.cs +++ b/SystemExtensions.NetStandard.Generators/NotifyPropertyChangedGenerator.cs @@ -150,7 +150,7 @@ public class NotifyPropertyChangedGenerator : IIncrementalGenerator } } - var fileSource = generatedSyntax.ToFullString(); + var fileSource = $"#nullable enable\n{generatedSyntax.ToFullString()}\n#nullable disable"; sourceProductionContext.AddSource($"{className}.g", fileSource); } } diff --git a/SystemExtensions.NetStandard.Generators/SystemExtensions.NetStandard.Generators.csproj b/SystemExtensions.NetStandard.Generators/SystemExtensions.NetStandard.Generators.csproj index 65f4ba1..7a454eb 100644 --- a/SystemExtensions.NetStandard.Generators/SystemExtensions.NetStandard.Generators.csproj +++ b/SystemExtensions.NetStandard.Generators/SystemExtensions.NetStandard.Generators.csproj @@ -5,7 +5,7 @@ true Alexandru Macocian Source generators extensions for netstandard2.0. - 0.1.5 + 0.1.6 latest true true