mirror of
https://github.com/UglyToad/PdfPig.git
synced 2025-04-05 20:55:01 +08:00
Fix warnings about "type 'K' cannot be used as type parameter 'TKey' in the generic type or method 'Dictionary<TKey, TValue>'"
This commit is contained in:
parent
c4576e4ffa
commit
24b9a99b8a
@ -16,7 +16,7 @@
|
|||||||
return code;
|
return code;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void PutAll<TKey, TValue>(this Dictionary<TKey, TValue> target, IReadOnlyDictionary<TKey, TValue> source)
|
public static void PutAll<TKey, TValue>(this Dictionary<TKey, TValue> target, IReadOnlyDictionary<TKey, TValue> source) where TKey : notnull
|
||||||
{
|
{
|
||||||
foreach (var pair in source)
|
foreach (var pair in source)
|
||||||
{
|
{
|
||||||
|
@ -5,7 +5,7 @@ namespace UglyToad.PdfPig.Util
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Diagnostics.CodeAnalysis;
|
using System.Diagnostics.CodeAnalysis;
|
||||||
|
|
||||||
internal class StackDictionary<K, V>
|
internal class StackDictionary<K, V> where K : notnull
|
||||||
{
|
{
|
||||||
private readonly List<Dictionary<K, V>> values = new List<Dictionary<K, V>>();
|
private readonly List<Dictionary<K, V>> values = new List<Dictionary<K, V>>();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user