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