File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -54,8 +54,6 @@ pub use core::slice::{from_raw_parts, from_raw_parts_mut};
54
54
pub use core:: slice:: { range, try_range} ;
55
55
#[ cfg( kani) ]
56
56
use crate :: kani;
57
- #[ cfg( kani) ]
58
- use core:: ptr:: slice_from_raw_parts;
59
57
60
58
////////////////////////////////////////////////////////////////////////////////
61
59
// Basic slice extension methods
@@ -529,9 +527,9 @@ impl<T> [T] {
529
527
let mut m = n >> 1 ;
530
528
// If `m > 0`, there are remaining bits up to the leftmost '1'.
531
529
#[ cfg( kani) ]
532
- let buf_ptr= slice_from_raw_parts ( buf. as_ptr ( ) , capacity) ;
530
+ let buf_ptr = ptr :: slice_from_raw_parts ( buf. as_ptr ( ) , capacity) ;
533
531
#[ cfg( kani) ]
534
- let len_ptr = unsafe { ( & buf as * const Vec < T > as * const usize ) . add ( 2 ) } ;
532
+ let len_ptr = unsafe { ( & buf as * const Vec < T > as * const usize ) . add ( 2 ) } ;
535
533
#[ kani:: loop_invariant(
536
534
kani:: mem:: same_allocation( buf. as_ptr( ) , buf. as_ptr( ) . wrapping_add( capacity) ) &&
537
535
unsafe { * len_ptr <= T :: MAX_SLICE_LEN } &&
You can’t perform that action at this time.
0 commit comments