pub(crate) unsafe fn append_to_string<F>( buf: &mut String, f: F ) -> Result<usize>where F: FnOnce(&mut Vec<u8>) -> Result<usize>,