pub struct GeneratedCodeArena { /* private fields */ }Expand description
An arena designed for the specific case of reading messages from single-segment
Word arrays in generated code, including constants and raw schema nodes. Performs
bounds checking, so its constructor does not need to be marked unsafe. Does
not enforce a read limit or a nesting limit.
Implementations§
Trait Implementations§
Source§impl ReaderArena for GeneratedCodeArena
impl ReaderArena for GeneratedCodeArena
fn get_segment(&self, id: u32) -> Result<(*const u8, u32)>
fn contains_interval( &self, id: u32, start: *const u8, size_in_words: usize, ) -> Result<()>
fn amplified_read(&self, _virtual_amount: u64) -> Result<()>
fn nesting_limit(&self) -> i32
fn size_in_words(&self) -> usize
unsafe fn check_offset( &self, segment_id: u32, start: *const u8, offset_in_words: i32, ) -> Result<*const u8>
Auto Trait Implementations§
impl Freeze for GeneratedCodeArena
impl RefUnwindSafe for GeneratedCodeArena
impl Send for GeneratedCodeArena
impl Sync for GeneratedCodeArena
impl Unpin for GeneratedCodeArena
impl UnsafeUnpin for GeneratedCodeArena
impl UnwindSafe for GeneratedCodeArena
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more