MCPcopy Create free account
hub / github.com/RustCrypto/utils / default

Method default

block-buffer/src/read.rs:22–28  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

20impl<BS: BlockSizes> Default for ReadBuffer<BS> {
21 #[inline]
22 fn default() -> Self {
23 let buffer = Default::default();
24 let mut res = Self { buffer };
25 // SAFETY: `BS::USIZE` satisfies the `set_pos_unchecked` safety contract
26 unsafe { res.set_pos_unchecked(BS::USIZE) };
27 res
28 }
29}
30
31impl<BS: BlockSizes> Clone for ReadBuffer<BS> {

Callers

nothing calls this directly

Calls 2

defaultFunction · 0.85
set_pos_uncheckedMethod · 0.45

Tested by

no test coverage detected