CL Unification: Function MAKE-SHARED-ENVIRONMENT
 

Function MAKE-SHARED-ENVIRONMENT

Package:

COMMON-LISP.EXTENSIONS.DATA-AND-CONTROL-FLOW.UNIFICATION

Syntax:

  make-shared-environment env
  => unification-environment
  

Arguments and Values:

env---an unification-environment.

unification-environment---a new unification-environment.

Description:

The function MAKE-SHARED-ENVIRONMENT constructs a new object of type UNIFY:ENVIRONMENT. The new unification-environment shares the frames already present in env.

It is guaranteed that extending unification-environment will not change env.

Affected By:

None.

Exceptional Situations:

None.

See Also:

UNIFY:ENVIRONMENT, BINDING, FIND-VARIABLE-VALUE

Notes:

This function is provided to allow for the construction of "trees" of frames for interpreter-like environments. The macros MATCH, MATCHF, MATCHING, MATCHF-CASE and MATCH-CASE rely on this function, as they immediately construct a "shared" environment.

Current Implementation Note

MAKE-SHARED-ENVIRONMENT relies on the LIST implementation of environments.