generated from amazon-archives/__template_Apache-2.0
-
Notifications
You must be signed in to change notification settings - Fork 135
Open
Labels
Z-ContractsIssue related to code contractsIssue related to code contracts[C] Feature / EnhancementA new feature request or enhancement to an existing feature.A new feature request or enhancement to an existing feature.
Milestone
Description
Requested feature: Contract verification should fail if the requires clause can never be satisfied
Use case: Detect user mistakes when writing contracts
Link to relevant documentation (Rust reference, Nomicon, RFC):
Test case:
#[kani::requires(a > 5)]
#[kani::requires(a < 4)]
#[kani::ensures(result == a)]
fn buggy(a: u32) -> u32 {
panic!("This code is never tested")
}Without vacuity test, this contract verification will pass.
JustusAdam and zjp-CN
Metadata
Metadata
Assignees
Labels
Z-ContractsIssue related to code contractsIssue related to code contracts[C] Feature / EnhancementA new feature request or enhancement to an existing feature.A new feature request or enhancement to an existing feature.