Testing Process
            
            #106
          
          
        -
| RustyRelic Repo 
 #[rustc_allow_const_fn_unstable(const_refs_to_cell)]
   #[requires({
       let size = core::mem::size_of::<T>();
       let ptr = &n as *const T as *const u8;
       let slice = unsafe { core::slice::from_raw_parts(ptr, size) };
       !slice.iter().all(|&byte| byte == 0)
   })]
 #[ensures(|result: &Self|{
        let size = core::mem::size_of::<T>();
        let n_ptr: *const T = &n;
        let result_inner: T = result.get();
        let result_ptr: *const T = &result_inner;
        let n_slice = unsafe { core::slice::from_raw_parts(n_ptr as *const u8, size) };
        let result_slice = unsafe { core::slice::from_raw_parts(result_ptr as *const u8, size) };
    
        n_slice == result_slice
    })]OUTPUT: SUMMARY:
 ** 0 of 1772 failed (2 unreachable)
VERIFICATION:- SUCCESSFUL
Verification Time: 0.57577264s
Complete - 1 successfully verified harnesses, 0 failures, 1 total. | 
Beta Was this translation helpful? Give feedback.
      
      
          Answered by
          
            celinval
          
      
      
        Oct 8, 2024 
      
    
    Replies: 1 comment
-
| Hi @aa-luna, unfortunately the only way to check contracts today is through Kani harnesses. We have this issue to enable it: model-checking/kani#3326. If this is something that you think would be helpful to you, please let us know so we can prioritize the issue. | 
Beta Was this translation helpful? Give feedback.
                  
                    0 replies
                  
                
            
      Answer selected by
        aa-luna
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
Hi @aa-luna, unfortunately the only way to check contracts today is through Kani harnesses.
We have this issue to enable it: model-checking/kani#3326. If this is something that you think would be helpful to you, please let us know so we can prioritize the issue.