From 896eb15477d111b74643bdf6c2d2e8e8f858d279 Mon Sep 17 00:00:00 2001 From: Stephen Toub Date: Mon, 23 Aug 2021 18:00:13 -0400 Subject: [PATCH] Remove several more #nullable disables (#57933) --- src/libraries/Common/src/System/CSharpHelpers.cs | 5 ++--- src/libraries/Common/src/System/HexConverter.cs | 1 - src/libraries/System.CodeDom/src/System.CodeDom.csproj | 1 + 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/libraries/Common/src/System/CSharpHelpers.cs b/src/libraries/Common/src/System/CSharpHelpers.cs index decc30b6a0a3c..2d8e28c2b231b 100644 --- a/src/libraries/Common/src/System/CSharpHelpers.cs +++ b/src/libraries/Common/src/System/CSharpHelpers.cs @@ -1,7 +1,6 @@ // Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. -#nullable disable using System.Collections.Generic; using System.Globalization; @@ -117,7 +116,7 @@ public static string CreateEscapedIdentifier(string name) /// independent identifier. /// /// - public static bool IsValidLanguageIndependentIdentifier(string value) + public static bool IsValidLanguageIndependentIdentifier(string? value) { return IsValidTypeNameOrIdentifier(value, false); } @@ -139,7 +138,7 @@ internal static bool IsPrefixTwoUnderscore(string value) } } - internal static bool IsValidTypeNameOrIdentifier(string value, bool isTypeName) + internal static bool IsValidTypeNameOrIdentifier(string? value, bool isTypeName) { bool nextMustBeStartChar = true; diff --git a/src/libraries/Common/src/System/HexConverter.cs b/src/libraries/Common/src/System/HexConverter.cs index bd3f5737a4953..c62aa8add553c 100644 --- a/src/libraries/Common/src/System/HexConverter.cs +++ b/src/libraries/Common/src/System/HexConverter.cs @@ -1,7 +1,6 @@ // Licensed to the .NET Foundation under one or more agreements. // The .NET Foundation licenses this file to you under the MIT license. -#nullable disable using System.Diagnostics; using System.Runtime.CompilerServices; #if SYSTEM_PRIVATE_CORELIB diff --git a/src/libraries/System.CodeDom/src/System.CodeDom.csproj b/src/libraries/System.CodeDom/src/System.CodeDom.csproj index fa0494af60b78..8446f3bb71c25 100644 --- a/src/libraries/System.CodeDom/src/System.CodeDom.csproj +++ b/src/libraries/System.CodeDom/src/System.CodeDom.csproj @@ -3,6 +3,7 @@ true $(DefineConstants);CODEDOM $(NetCoreAppCurrent);netstandard2.0;net461 + annotations false true Provides types that can be used to model the structure of a source code document and to output source code for that model in a supported language.