mirror of
https://github.com/github/codeql.git
synced 2026-04-30 19:26:02 +02:00
C#: Fix type parameter names
This commit is contained in:
@@ -7,11 +7,11 @@ namespace Semmle.Util
|
||||
/// A dictionary which performs an action when items are added to the dictionary.
|
||||
/// The order in which keys and actions are added does not matter.
|
||||
/// </summary>
|
||||
/// <typeparam name="Key"></typeparam>
|
||||
/// <typeparam name="Value"></typeparam>
|
||||
public class ActionMap<Key, Value> where Key : notnull
|
||||
/// <typeparam name="TKey"></typeparam>
|
||||
/// <typeparam name="TValue"></typeparam>
|
||||
public class ActionMap<TKey, TValue> where TKey : notnull
|
||||
{
|
||||
public void Add(Key key, Value value)
|
||||
public void Add(TKey key, TValue value)
|
||||
{
|
||||
|
||||
if (actions.TryGetValue(key, out var a))
|
||||
@@ -19,7 +19,7 @@ namespace Semmle.Util
|
||||
values[key] = value;
|
||||
}
|
||||
|
||||
public void OnAdd(Key key, Action<Value> action)
|
||||
public void OnAdd(TKey key, Action<TValue> action)
|
||||
{
|
||||
if (actions.TryGetValue(key, out var a))
|
||||
{
|
||||
@@ -37,9 +37,9 @@ namespace Semmle.Util
|
||||
}
|
||||
|
||||
// Action associated with each key.
|
||||
private readonly Dictionary<Key, Action<Value>> actions = new Dictionary<Key, Action<Value>>();
|
||||
private readonly Dictionary<TKey, Action<TValue>> actions = new Dictionary<TKey, Action<TValue>>();
|
||||
|
||||
// Values associated with each key.
|
||||
private readonly Dictionary<Key, Value> values = new Dictionary<Key, Value>();
|
||||
private readonly Dictionary<TKey, TValue> values = new Dictionary<TKey, TValue>();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user