Keyboard shortcuts

Press or to navigate between chapters

Press ? to show this help

Press Esc to hide this help

sha256_u256

Computes SHA256 hash directly from ByteArray input to u256 output.

Optimized version of sha256 that works directly with ByteArray data without requiring last conversion to u256.

Arguments

  • data - Input data as a ByteArray reference

Returns

  • u256 - 32-byte SHA256 hash result

Usage

Efficient SHA256 computation when working with u256 outputs.

Fully qualified path: alexandria_btc::hash::sha256_u256

pub fn sha256_u256(data: @ByteArray) -> u256