You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
HeaderMap<T> implements TryFrom<&'a HashMap<K, T>>. However, this only covers hashmaps created with the default S = RandomState hashing algorithm / state.
If you've gathered some headers from elsewhere (in my case: in a Python library with PyO3) and you want to turn those into a HeaderMap for use in a HTTP client, there is no need to use a HashDoS-resistant hashing function, so being able to use a hashmap with a different hashing function would be great.
As far as I can tell, there is no reason why the current implementation could not work for other hashmaps. The only thing that needs to change is exposing S parameter as well in the trait implementation bounds.
The text was updated successfully, but these errors were encountered:
HeaderMap<T>
implementsTryFrom<&'a HashMap<K, T>>
. However, this only covers hashmaps created with the defaultS = RandomState
hashing algorithm / state.If you've gathered some headers from elsewhere (in my case: in a Python library with PyO3) and you want to turn those into a HeaderMap for use in a HTTP client, there is no need to use a HashDoS-resistant hashing function, so being able to use a hashmap with a different hashing function would be great.
As far as I can tell, there is no reason why the current implementation could not work for other hashmaps. The only thing that needs to change is exposing
S
parameter as well in the trait implementation bounds.The text was updated successfully, but these errors were encountered: