Skip to content

Commit bc69ecd

Browse files
krwqstephentoub
authored andcommitted
Nullable: Globalization native interop + some missing files (dotnet#23914)
* Nullable: globalization native + some missing files * address feedback
1 parent 5d420c4 commit bc69ecd

17 files changed

+38
-22
lines changed

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.Calendar.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System;
67
using System.Globalization;
78
using System.Runtime.InteropServices;

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.Casing.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System;
67
using System.Runtime.InteropServices;
78
using System.Security;

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.Collation.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System;
67
using System.Globalization;
78
using System.Runtime.InteropServices;

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.ICU.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System;
67
using System.Runtime.InteropServices;
78
using System.Runtime.CompilerServices;

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.Idna.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System;
67
using System.Runtime.InteropServices;
78

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.Locale.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System;
67
using System.Runtime.InteropServices;
78

@@ -34,6 +35,6 @@ internal static partial class Globalization
3435
internal static extern bool GetLocaleInfoGroupingSizes(string localeName, uint localeGroupingData, ref int primaryGroupSize, ref int secondaryGroupSize);
3536

3637
[DllImport(Libraries.GlobalizationNative, CharSet = CharSet.Unicode, EntryPoint = "GlobalizationNative_GetLocales")]
37-
internal static extern int GetLocales([Out] char[] value, int valueLength);
38+
internal static extern int GetLocales([Out] char[]? value, int valueLength);
3839
}
3940
}

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.Normalization.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System;
67
using System.Runtime.InteropServices;
78
using System.Text;

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.ResultCode.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
internal static partial class Interop
67
{
78
internal static partial class Globalization

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.TimeZoneInfo.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System.Runtime.InteropServices;
67
using System.Text;
78

src/System.Private.CoreLib/shared/Interop/Unix/System.Globalization.Native/Interop.Utils.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33
// See the LICENSE file in the project root for more information.
44

5+
#nullable enable
56
using System;
67
using System.Diagnostics;
78
using System.Buffers;
@@ -17,7 +18,7 @@ internal static partial class Interop
1718
internal static bool CallStringMethod<TArg1, TArg2, TArg3>(
1819
SpanFunc<char, TArg1, TArg2, TArg3, Interop.Globalization.ResultCode> interopCall,
1920
TArg1 arg1, TArg2 arg2, TArg3 arg3,
20-
out string result)
21+
out string? result)
2122
{
2223
const int InitialSize = 256; // arbitrary stack allocation size
2324
const int MaxHeapSize = 1280; // max from previous version of the code, starting at 80 and doubling four times

0 commit comments

Comments
 (0)