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