[#absl-HashState-Create]
= xref:absl.adoc[absl]::xref:absl/HashState.adoc[HashState]::Create
:relfileprefix: ../../
:mrdocs:

Create a new `HashState` instance that wraps `state`&period;

== Synopsis

Declared in `&lt;absl&sol;hash&sol;hash&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;typename T&gt;
requires std&colon;&colon;is&lowbar;base&lowbar;of&lowbar;v&lt;hash&lowbar;internal&colon;&colon;HashStateBase&lt;T&gt;, T&gt;
static
xref:absl/HashState.adoc[HashState]
Create(T* state);
----

== Description

All calls to `combine()` and `combine&lowbar;contiguous()` on the new instance will be redirected to the original `state` object&period; The `state` object must outlive the `HashState` instance&period; `T` must be a subclass of `HashStateBase&lt;T&gt;` &hyphen; users should not define their own HashState types&period;

== Return Value

A type&hyphen;erased `HashState` wrapping `state`&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *state*
| The underlying hash state to wrap&period;
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
