Skip to content

Commit

Permalink
feat: add proof for Bytecode.MoveLoc
Browse files Browse the repository at this point in the history
  • Loading branch information
0xMushow committed Dec 19, 2024
1 parent 2cdf5fd commit 03777d5
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion CoqOfRust/move_sui/proofs/move_bytecode_verifier/type_safety.v
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,24 @@ Proof.
apply H.
}
{ guard_instruction (Bytecode.MoveLoc z).
admit.
destruct H_type_safety_checker as [H_stack].
pose proof (TypeSafetyChecker.Impl_TypeSafetyChecker.push
(TypeSafetyChecker.Impl_TypeSafetyChecker.local_at type_safety_checker {| file_format_index.LocalIndex.a0 := z |})
type_safety_checker
).
unfold TypeSafetyChecker.Impl_TypeSafetyChecker.push.
with_strategy opaque [AbstractStack.push] unfold_state_monad.
pose proof (AbstractStack.push_is_valid
(TypeSafetyChecker.Impl_TypeSafetyChecker.local_at type_safety_checker {| file_format_index.LocalIndex.a0 := z |})
type_safety_checker.(TypeSafetyChecker.stack)
H_stack
).
do 2 (step; cbn; trivial).
unfold safe_unwrap_err.
step; cbn; trivial.
destruct u.
constructor; cbn.
apply H0.
}
{ guard_instruction (Bytecode.StLoc z).
unfold_state_monad.
Expand Down

0 comments on commit 03777d5

Please sign in to comment.