You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
namespace DS.Module.Core.Helpers;
|
|
|
|
|
|
|
|
|
|
public static class ArrayHelper
|
|
|
|
|
{
|
|
|
|
|
public static T[] Empty<T>() =>
|
|
|
|
|
#if NET45
|
|
|
|
|
|
|
|
|
|
EmptyArray<T>.Value
|
|
|
|
|
#else
|
|
|
|
|
Array.Empty<T>()
|
|
|
|
|
#endif
|
|
|
|
|
;
|
|
|
|
|
|
|
|
|
|
#if NET45
|
|
|
|
|
private static class EmptyArray<T>
|
|
|
|
|
{
|
|
|
|
|
public static readonly T[] Value = new T[0];
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
}
|