Check whether a variable is in scope.
A variable in scope does not necessarily have a value. A variable which is declared (see declare-var-env) but not initialized, or whose value is unknown.
Function:
(defun in-scope-env (ident env) (declare (xargs :guard (and (identp ident) (envp env)))) (declare (xargs :type-prescription (booleanp (in-scope-env ident env)))) (let ((__function__ 'in-scope-env)) (declare (ignorable __function__)) (and (consp env) (or (and (omap::assoc ident (first env)) t) (in-scope-env ident (rest env))))))