Negative coverage: borrow_check_place_expr / struct field / premise prove_ty_is_rigid(env, assumptions, state, &prefix_typed.ty) => (RigidTy { name: RigidName::AdtId(adt_id), parameters }, state)
Premise at line 727. Observed failure causes: if_let.
struct field| Line | Coverage | Source |
|---|---|---|
| 726 | ✗ | (borrow_check_place_expr(env, assumptions, state, prefix) => (prefix_typed, state)) |
| 727 | 1 | (prove_ty_is_rigid(env, assumptions, state, &prefix_typed.ty) => (RigidTy { name: RigidName::AdtId(adt_id), parameters }, state)) |
| 728 | ✗ | (let Struct { id: _, binder } = env.crates().struct_named(&adt_id)?) |
| 729 | ✗ | (let StructBoundData { where_clauses, fields } = binder.instantiate_with(¶meters)?) |
| 730 | ✗ | (prove_where_clauses(env, assumptions, state, where_clauses) => state) |
| 731 | ✗ | (field in fields) |
| 732 | 1 | (if field.name == *field_name) |
| ──────── ("struct field") | ||
| 734 | 24 | (borrow_check_place_expr(env, assumptions, state, PlaceExpr::Field { prefix, field_name }) => ( TypedPlaceExpr::new(&field.ty, TypedPlaceExpressionData::field(prefix_typed, field_name, adt_id, VariantId::for_struct())), state, )) |
1 test failed proving this premise:
Source location: tests/mir_typeck.rs:820 (all coverage from this test)
fn foo (v1: u32) -> u32 {
let v2: Dummy = Dummy { value: 1_u32 };
v1.value = 2_u32;
return v1;
}
Failed proof tree
check_all_crates failedmod.rs:42args
rule "check all prefixes"mod.rs:54check_crate failedmod.rs:61args
rule "check crate"mod.rs:75check_crate_item failedmod.rs:180rule "free fn"mod.rs:208check_free_fn failedfns.rs:14args
rule "check free fn"fns.rs:24check_fn failedfns.rs:31args
rule "check fn"fns.rs:54check_fn_body failedfns.rs:61args
rule "expr fn body"fns.rs:89borrow_check failednll.rs:124args
rule "borrow_check"nll.rs:135borrow_check_block failednll.rs:144rule "basic block"nll.rs:159borrow_check_statement failednll.rs:176args
rule "expr"nll.rs:234borrow_check_expr failednll.rs:375args
rule "assign"nll.rs:445borrow_check_place_expr failednll.rs:706args
rule "struct field"nll.rs:727 (failed: if_let)