MCPcopy Create free account
hub / github.com/Vectorized/function-selector-miner / fill_sponge_single

Method fill_sponge_single

src/sponge.rs:73–81  ·  view source on GitHub ↗
(
        &mut self,
        offset: usize,
        s: &SmallString,
    )

Source from the content-addressed store, hash-verified

71 /// This function is unsafe because it writes to a union type.
72 #[inline(always)]
73 pub unsafe fn fill_sponge_single<const N: usize>(
74 &mut self,
75 offset: usize,
76 s: &SmallString,
77 ) -> usize {
78 let n = if N == 0 { s.length } else { N };
79 self.chars[offset..][..n].copy_from_slice(&s.data[..n]);
80 s.length
81 }
82
83 /// # Safety
84 ///

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected