From a77f3401edde2f1ac2d02ba0e2971d16118484f7 Mon Sep 17 00:00:00 2001 From: Staffan Gustafsson Date: Thu, 19 Nov 2020 23:54:21 +0100 Subject: [PATCH 1/3] Enable nullable: System.Management.Automation.IContainsErrorRecord --- src/System.Management.Automation/engine/ErrorPackage.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/System.Management.Automation/engine/ErrorPackage.cs b/src/System.Management.Automation/engine/ErrorPackage.cs index 4d1627dff93..565b8a916a8 100644 --- a/src/System.Management.Automation/engine/ErrorPackage.cs +++ b/src/System.Management.Automation/engine/ErrorPackage.cs @@ -1717,6 +1717,8 @@ public ErrorRecord(Exception exception, string errorId, ErrorCategory errorCateg } } +#nullable enable + /// /// Implemented by exception classes which contain additional /// @@ -1790,6 +1792,8 @@ public interface IContainsErrorRecord ErrorRecord ErrorRecord { get; } } +#nullable restore + /// /// Objects implementing this interface can be used by /// From a4da1f2dedba922a840604326ee61593cffa1dc3 Mon Sep 17 00:00:00 2001 From: Staffan Gustafsson Date: Fri, 20 Nov 2020 15:43:33 +0100 Subject: [PATCH 2/3] Removing empty lines before and after pragma --- src/System.Management.Automation/engine/ErrorPackage.cs | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/System.Management.Automation/engine/ErrorPackage.cs b/src/System.Management.Automation/engine/ErrorPackage.cs index 565b8a916a8..dec8231070a 100644 --- a/src/System.Management.Automation/engine/ErrorPackage.cs +++ b/src/System.Management.Automation/engine/ErrorPackage.cs @@ -1718,7 +1718,6 @@ public ErrorRecord(Exception exception, string errorId, ErrorCategory errorCateg } #nullable enable - /// /// Implemented by exception classes which contain additional /// @@ -1791,7 +1790,6 @@ public interface IContainsErrorRecord /// ErrorRecord ErrorRecord { get; } } - #nullable restore /// From 1228bc4fec3075b2fc33f5d16c941c34e192bd4d Mon Sep 17 00:00:00 2001 From: Staffan Gustafsson Date: Fri, 20 Nov 2020 19:36:11 +0100 Subject: [PATCH 3/3] Removing whitespace before/after nullable pragma --- src/System.Management.Automation/engine/ErrorPackage.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/System.Management.Automation/engine/ErrorPackage.cs b/src/System.Management.Automation/engine/ErrorPackage.cs index dec8231070a..0395daa7613 100644 --- a/src/System.Management.Automation/engine/ErrorPackage.cs +++ b/src/System.Management.Automation/engine/ErrorPackage.cs @@ -1717,7 +1717,6 @@ public ErrorRecord(Exception exception, string errorId, ErrorCategory errorCateg } } -#nullable enable /// /// Implemented by exception classes which contain additional /// @@ -1762,6 +1761,7 @@ public ErrorRecord(Exception exception, string errorId, ErrorCategory errorCateg /// /// is no longer available. /// +#nullable enable public interface IContainsErrorRecord { ///