* Make mac/win lookups lowercase'd * Revert #709 & 81042cc * Adjust HashPolicy implementation across sourcemod Basically, in order to implement our own (actual) hash policy in `PluginSys.h`, we needed to remove the blanket implementation of `hash` that was used before. Now, each policy must implement `hash` along with `matches` in order to be used with `NameHashSet`. While this does force us to change every implementation of policies across the entirety of sourcemod, it allows core to use flexible implementations of `hash`. * Remove logic duplication * Improve lowercase checks
This commit is contained in:
committed by
Nicholas Hastings
parent
daee19d502
commit
aaac0b9eb2
@@ -111,6 +111,10 @@ struct QHandleType
|
||||
{
|
||||
return type->name && type->name->compare(key) == 0;
|
||||
}
|
||||
static inline uint32_t hash(const detail::CharsAndLength &key)
|
||||
{
|
||||
return key.hash();
|
||||
}
|
||||
};
|
||||
|
||||
typedef ke::Lambda<void(const char *)> HandleReporter;
|
||||
|
||||
Reference in New Issue
Block a user