MCPcopy Index your code
hub / github.com/RustPython/RustPython / truncate

Method truncate

crates/wtf8/src/lib.rs:503–506  ·  view source on GitHub ↗
(&mut self, new_len: usize)

Source from the content-addressed store, hash-verified

501 /// or if `new_len` is not a code point boundary.
502 #[inline]
503 pub fn truncate(&mut self, new_len: usize) {
504 assert!(is_code_point_boundary(self, new_len));
505 self.bytes.truncate(new_len)
506 }
507
508 /// Inserts a codepoint into this `Wtf8Buf` at a byte position.
509 #[inline]

Callers 6

get_channel_bindingMethod · 0.45
readMethod · 0.45
getsockoptMethod · 0.45
recvFunction · 0.45
readMethod · 0.45
popMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected