* 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
@@ -58,6 +58,10 @@ struct maplist_info_t
|
||||
{
|
||||
return strcmp(value->name, key) == 0;
|
||||
}
|
||||
static inline uint32_t hash(const detail::CharsAndLength &key)
|
||||
{
|
||||
return key.hash();
|
||||
}
|
||||
};
|
||||
|
||||
#define MAPLIST_FLAG_MAPSFOLDER (1<<0) /**< On failure, use all maps in the maps folder. */
|
||||
|
||||
Reference in New Issue
Block a user