referrerpolicy=no-referrer-when-downgrade
sp_io::storage

Function root

Source
pub fn root(
    version: <PassAs<StateVersion, u8> as RIType>::Inner,
) -> <AllocateAndReturnFatPointer<Vec<u8>> as RIType>::Inner
Expand description

“Commit” all existing operations and compute the resulting storage root.

The hashing algorithm is defined by the Block.

Returns a Vec<u8> that holds the SCALE encoded hash.