Rollback default(T) is { } as I'm not sure that's good.
MODIFY
WalletWasabi/Nito/Collections/Deque.cs
WalletWasabi/Nito/Collections/Deque.cs
@@ -168,7 +168,7 @@ namespace Nito.Collections
set
{
- if (value is null && default(T) is { })
+ if (value is null && default(T) != null)
{
throw new ArgumentNullException(nameof(value), $"{nameof(value)} cannot be null.");
}
@@ -392,7 +392,7 @@ namespace Nito.Collections
int IList.Add(object value)
{
- if (value is null && default(T) is { })
+ if (value is null && default(T) != null)
{
throw new ArgumentNullException(nameof(value), $"{nameof(value)} cannot be null.");
}
@@ -418,7 +418,7 @@ namespace Nito.Collections
void IList.Insert(int index, object value)
{
- if (value is null && default(T) is { })
+ if (value is null && default(T) != null)
{
throw new ArgumentNullException(nameof(value), $"{nameof(value)} cannot be null.");
}

Rollback default(T) is { } as I'm not sure that's good.