(check-transform-args args arg-info default-arg-info ctxt) → err?
Function:
(defun check-transform-args (args arg-info default-arg-info ctxt) (declare (xargs :guard (and (transform-argument-listp args) (alistp arg-info) (alistp default-arg-info) (contextp ctxt)))) (let ((__function__ 'check-transform-args)) (declare (ignorable __function__)) (if (endp args) (let ((remaining-required-args (args-without-defaults arg-info default-arg-info))) (and remaining-required-args (list :missing-fields remaining-required-args))) (b* (((transform-argument arg) (car args)) (arg-name (identifier->name arg.name)) (this-arg-info (assoc-equal arg-name arg-info)) ((unless this-arg-info) (list :unknown-transform-field arg-name))) (check-transform-args (cdr args) (remove-equal this-arg-info arg-info) default-arg-info ctxt)))))
Theorem:
(defthm check-transform-args-of-transform-argument-list-fix-args (equal (check-transform-args (transform-argument-list-fix args) arg-info default-arg-info ctxt) (check-transform-args args arg-info default-arg-info ctxt)))
Theorem:
(defthm check-transform-args-transform-argument-list-equiv-congruence-on-args (implies (transform-argument-list-equiv args args-equiv) (equal (check-transform-args args arg-info default-arg-info ctxt) (check-transform-args args-equiv arg-info default-arg-info ctxt))) :rule-classes :congruence)
Theorem:
(defthm check-transform-args-of-context-fix-ctxt (equal (check-transform-args args arg-info default-arg-info (context-fix ctxt)) (check-transform-args args arg-info default-arg-info ctxt)))
Theorem:
(defthm check-transform-args-context-equiv-congruence-on-ctxt (implies (context-equiv ctxt ctxt-equiv) (equal (check-transform-args args arg-info default-arg-info ctxt) (check-transform-args args arg-info default-arg-info ctxt-equiv))) :rule-classes :congruence)