Get the unwrap field from a amb?-decl/stmt-ambig.
(amb?-decl/stmt-ambig->unwrap x) → unwrap
This is an ordinary field accessor created by fty::defprod.
Function:
(defun amb?-decl/stmt-ambig->unwrap$inline (x) (declare (xargs :guard (amb?-decl/stmt-p x))) (declare (xargs :guard (equal (amb?-decl/stmt-kind x) :ambig))) (let ((__function__ 'amb?-decl/stmt-ambig->unwrap)) (declare (ignorable __function__)) (mbe :logic (b* ((x (and (equal (amb?-decl/stmt-kind x) :ambig) x))) (amb-decl/stmt-fix (std::da-nth 0 (cdr x)))) :exec (std::da-nth 0 (cdr x)))))
Theorem:
(defthm amb-decl/stmt-p-of-amb?-decl/stmt-ambig->unwrap (b* ((unwrap (amb?-decl/stmt-ambig->unwrap$inline x))) (amb-decl/stmt-p unwrap)) :rule-classes :rewrite)
Theorem:
(defthm amb?-decl/stmt-ambig->unwrap$inline-of-amb?-decl/stmt-fix-x (equal (amb?-decl/stmt-ambig->unwrap$inline (amb?-decl/stmt-fix x)) (amb?-decl/stmt-ambig->unwrap$inline x)))
Theorem:
(defthm amb?-decl/stmt-ambig->unwrap$inline-amb?-decl/stmt-equiv-congruence-on-x (implies (amb?-decl/stmt-equiv x x-equiv) (equal (amb?-decl/stmt-ambig->unwrap$inline x) (amb?-decl/stmt-ambig->unwrap$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm amb?-decl/stmt-ambig->unwrap-when-wrong-kind (implies (not (equal (amb?-decl/stmt-kind x) :ambig)) (equal (amb?-decl/stmt-ambig->unwrap x) (amb-decl/stmt-fix nil))))