pub(super) fn stable64_grow(&mut self, additional_pages: u64) -> HypervisorResult<i64> {
        let initial_page_count = self.stable64_size()?;

        let (page_count, overflow) = additional_pages.overflowing_add(initial_page_count);
        if overflow || page_count > MAX_64_BIT_STABLE_MEMORY_IN_PAGES as u64 {
            return Ok(-1);
        }

        self.stable_memory_size =
            NumWasmPages::from(initial_page_count as usize + additional_pages as usize);

        Ok(initial_page_count as i64)
    }
/// Grows stable memory by specified amount.
Grows stable memory by specified amount.
Grows stable memory by specified amount .
pub(super) fn stable64_grow(&mut self, additional_pages: u64) -> HypervisorResult<i64> {
        let initial_page_count = self.stable64_size()?;
        let (page_count, overflow) = additional_pages.overflowing_add(initial_page_count);
        if overflow || page_count > MAX_64_BIT_STABLE_MEMORY_IN_PAGES as u64 {
            return Ok(-1);
        }
        self.stable_memory_size =
            NumWasmPages::from(initial_page_count as usize + additional_pages as usize);
        Ok(initial_page_count as i64)
    }
pub ( super ) fn stable64_grow ( & mut self , additional_pages : u64 ) -> HypervisorResult < i64 > { let initial_page_count = self . stable64_size ( ) ? ; let ( page_count , overflow ) = additional_pages . overflowing_add ( initial_page_count ) ; if overflow || page_count > MAX_64_BIT_STABLE_MEMORY_IN_PAGES as u64 { return Ok ( - 1 ) ; } self . stable_memory_size = NumWasmPages :: from ( initial_page_count as usize + additional_pages as usize ) ; Ok ( initial_page_count as i64 ) }
Grows stable memory by specified amount.
Grows stable memory by specified amount .
&mut self
additional_pages
u64
&mut self
additional_pages
u64