[#bsl-hash-017] = xref:bsl.adoc[bsl]::xref:bsl/hash-06.adoc[hash]<xref:bsl/basic_string-0faf.adoc[basic_string<CHAR_TYPE, CHAR_TRAITS, ALLOCATOR>]> :relfileprefix: ../ :mrdocs: Specialize `bsl::hash` for strings, including an overload for pointers to allow character arrays to be hashed without converting them first. == Synopsis Declared in `<bslstl_string.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template< class CHAR_TYPE, class CHAR_TRAITS, class ALLOCATOR> struct xref:bsl/hash-06.adoc[hash]<xref:bsl/basic_string-0faf.adoc[basic_string<CHAR_TYPE, CHAR_TRAITS, ALLOCATOR>]> : xref:BloombergLP/bslh/Hash-07.adoc[BloombergLP::bslh::Hash<>] ---- == Base Classes [cols="1,4"] |=== | Name| Description | `xref:BloombergLP/bslh/Hash-07.adoc[BloombergLP::bslh::Hash<>]` | This struct wraps the (template parameter) type `HASH_ALGORITHM` in an interface that satisfies the `hash` requirements of the C++11 standard. |=== == Type Aliases [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bslh/Hash-02/HashAlgorithm.adoc[`HashAlgorithm`] | Make the `HASH_ALGORITHM` template parameter available to clients. | xref:BloombergLP/bslh/Hash-02/result_type.adoc[`result_type`] | The type of the hash value that will be returned by the function‐call operator. |=== == Member Functions [cols="1,4"] |=== | Name| Description | xref:bsl/hash-017/operator_call-01.adoc[`operator()`] | Function call operators |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#