1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-08 03:28:20 +02:00

GetValueAlt

This commit is contained in:
Brian Fiete 2025-06-02 10:47:53 +02:00
parent 9e9b170548
commit bbf057a59c

View file

@ -269,6 +269,13 @@ namespace System.Collections
return .Err; return .Err;
} }
public Result<TValue> GetValueAlt<TAltKey>(TAltKey key) where TAltKey : IHashable where bool : operator TKey == TAltKey
{
int_cosize i = (int_cosize)FindEntryAlt(key);
if (i >= 0) return mEntries[i].mValue;
return .Err;
}
public void Clear() public void Clear()
{ {
if (mCount > 0) if (mCount > 0)