Get the kwd field from a pinst-keypair.
This is an ordinary field accessor created by fty::defprod.
Function:
(defun pinst-keypair->kwd$inline (x) (declare (xargs :guard (pinst-p x))) (declare (xargs :guard (equal (pinst-kind x) :keypair))) (let ((acl2::__function__ 'pinst-keypair->kwd)) (declare (ignorable acl2::__function__)) (mbe :logic (b* ((x (and (equal (pinst-kind x) :keypair) x))) (pflat-fix (std::prod-car (std::prod-cdr (cdr x))))) :exec (std::prod-car (std::prod-cdr (cdr x))))))
Theorem:
(defthm pflat-p-of-pinst-keypair->kwd (b* ((kwd (pinst-keypair->kwd$inline x))) (pflat-p kwd)) :rule-classes :rewrite)
Theorem:
(defthm pinst-keypair->kwd$inline-of-pinst-fix-x (equal (pinst-keypair->kwd$inline (pinst-fix x)) (pinst-keypair->kwd$inline x)))
Theorem:
(defthm pinst-keypair->kwd$inline-pinst-equiv-congruence-on-x (implies (pinst-equiv x x-equiv) (equal (pinst-keypair->kwd$inline x) (pinst-keypair->kwd$inline x-equiv))) :rule-classes :congruence)
Theorem:
(defthm pinst-keypair->kwd-when-wrong-kind (implies (not (equal (pinst-kind x) :keypair)) (equal (pinst-keypair->kwd x) (pflat-fix nil))))