This is an ordinary defenum.
Function:
(defun vl-opacity-p (x) (declare (xargs :guard t)) (or (eq x ':transparent) (eq x ':opaque) (eq x ':special)))
Theorem: type-when-vl-opacity-p
(defthm type-when-vl-opacity-p (implies (vl-opacity-p x) (if (symbolp x) (if (not (equal x 't)) (not (equal x 'nil)) 'nil) 'nil)) :rule-classes :compound-recognizer)