File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -455,9 +455,10 @@ mod tests {
455455
456456 type MmapRegion = super :: MmapRegion < ( ) > ;
457457
458- // Adding a helper method to extract the errno within an Error::Mmap(e), or return a
459- // distinctive value when the error is represented by another variant.
460458 impl Error {
459+ /// Helper method to extract the errno within an
460+ /// `Error::Mmap(e)`. Returns `i32::MIN` if `self` is any
461+ /// other variant.
461462 pub fn raw_os_error ( & self ) -> i32 {
462463 match self {
463464 Error :: Mmap ( e) => e. raw_os_error ( ) . unwrap ( ) ,
Original file line number Diff line number Diff line change @@ -1063,6 +1063,7 @@ mod tests {
10631063 }
10641064
10651065 impl MmapRegion {
1066+ /// Create an `MmapRegion` with specified `size` at GuestAdress(0)
10661067 pub fn new ( size : usize ) -> Result < Self > {
10671068 let range = MmapRange :: new_unix ( size, None , GuestAddress ( 0 ) ) ;
10681069 Self :: from_range ( range)
You can’t perform that action at this time.
0 commit comments