Lines Matching refs:reader
253 let reader = Rc::new(RefCell::new(BytesReader::new(BytesMut::new()))); in test_rc_refcell() localVariable
255 reader.borrow_mut().extend_from_slice(&xs[..]); in test_rc_refcell()
257 let mut rv = reader.borrow_mut().read_u8().unwrap(); in test_rc_refcell()
260 rv = reader.borrow_mut().read_u8().unwrap(); in test_rc_refcell()
263 rv = reader.borrow_mut().read_u8().unwrap(); in test_rc_refcell()
268 pub reader: Rc<RefCell<BytesReader>>, field
272 pub fn new(reader: Rc<RefCell<BytesReader>>) -> Self { in new()
273 Self { reader } in new()
281 self.reader.borrow_mut().extend_from_slice(data); in extend_from_slice()
287 let reader = Rc::new(RefCell::new(BytesReader::new(BytesMut::new()))); in test_struct_rc_refcell() localVariable
289 let mut ref_struct = RefStruct::new(reader); in test_struct_rc_refcell()
294 let mut reader = ref_struct.reader.borrow_mut(); in test_struct_rc_refcell() localVariable
296 let mut rv = reader.read_u8().unwrap(); in test_struct_rc_refcell()
299 rv = reader.read_u8().unwrap(); in test_struct_rc_refcell()
302 rv = reader.read_u8().unwrap(); in test_struct_rc_refcell()