MCPcopy Create free account
hub / github.com/RustCrypto/formats / last

Method last

der/src/arrayvec.rs:65–67  ·  view source on GitHub ↗

Get the last item from this [`ArrayVec`].

(&self)

Source from the content-addressed store, hash-verified

63
64 /// Get the last item from this [`ArrayVec`].
65 pub fn last(&self) -> Option<&T> {
66 self.length.checked_sub(1).and_then(|n| self.get(n))
67 }
68
69 /// Extract the inner array.
70 pub fn into_array(self) -> [Option<T>; N] {

Callers 3

compress_yMethod · 0.80
addMethod · 0.80
decodeMethod · 0.80

Calls 1

getMethod · 0.45

Tested by

no test coverage detected