@@ -342,8 +342,8 @@ where
342342            let  end_inclusive_copy_address = cmp:: min ( end_inclusive_addr,  page_end_inclusive) ; 
343343
344344            // These are the offsets into the frame we want to copy from. 
345-             let  start_offset_in_frame = ( start_copy_address - page_start)   as   usize ; 
346-             let  end_inclusive_offset_in_frame = ( end_inclusive_copy_address - page_start)   as   usize ; 
345+             let  start_offset_in_frame = start_copy_address - page_start; 
346+             let  end_inclusive_offset_in_frame = end_inclusive_copy_address - page_start; 
347347
348348            // Calculate how many bytes we want to copy from this frame. 
349349            let  copy_len = end_inclusive_offset_in_frame - start_offset_in_frame + 1 ; 
@@ -362,11 +362,11 @@ where
362362                // SAFETY: We know that this memory is valid because we got it 
363363                // as a result from a translation. There are not other 
364364                // references to it. 
365-                 & * core:: ptr:: slice_from_raw_parts ( src_ptr,  copy_len) 
365+                 & * core:: ptr:: slice_from_raw_parts ( src_ptr,  copy_len  as   usize ) 
366366            } ; 
367367
368368            // Calculate the destination pointer. 
369-             let  dest = & mut  buf[ start_offset_in_buf..] [ ..copy_len] ; 
369+             let  dest = & mut  buf[ start_offset_in_buf..] [ ..copy_len  as   usize ] ; 
370370
371371            // Do the actual copy. 
372372            dest. copy_from_slice ( src) ; 
@@ -409,8 +409,8 @@ where
409409            let  end_inclusive_copy_address = cmp:: min ( end_inclusive_addr,  page_end_inclusive) ; 
410410
411411            // These are the offsets into the frame we want to copy from. 
412-             let  start_offset_in_frame = ( start_copy_address - page_start)   as   usize ; 
413-             let  end_inclusive_offset_in_frame = ( end_inclusive_copy_address - page_start)   as   usize ; 
412+             let  start_offset_in_frame = start_copy_address - page_start; 
413+             let  end_inclusive_offset_in_frame = end_inclusive_copy_address - page_start; 
414414
415415            // Calculate how many bytes we want to copy from this frame. 
416416            let  copy_len = end_inclusive_offset_in_frame - start_offset_in_frame + 1 ; 
@@ -429,11 +429,11 @@ where
429429                // SAFETY: We know that this memory is valid because we got it 
430430                // as a result from a translation. There are not other 
431431                // references to it. 
432-                 & mut  * core:: ptr:: slice_from_raw_parts_mut ( dest_ptr,  copy_len) 
432+                 & mut  * core:: ptr:: slice_from_raw_parts_mut ( dest_ptr,  copy_len  as   usize ) 
433433            } ; 
434434
435435            // Calculate the destination pointer. 
436-             let  src = & buf[ start_offset_in_buf..] [ ..copy_len] ; 
436+             let  src = & buf[ start_offset_in_buf..] [ ..copy_len  as   usize ] ; 
437437
438438            // Do the actual copy. 
439439            dest. copy_from_slice ( src) ; 
0 commit comments