anchor.diff:  (defparameter *shell-environment-handlers* (make-hash-table))
   
   (defun extend-shell-environment (name pickler unpickler reclaimer)
  +  "Enroll some state as part of the shell environment.
  +
  +The shell environment is just a bunch of state.  Changes to shell
  +environment state must be confined to the subshell where the change
  +occured.  In a normal shell, this is accomplished by forking the shell
  +process when creating a subshell.  Forking naturally confines state
  +changes to the subshell.  SHCL doesn't fork when creating subshells,
  +so state must be managed manually.  This function gives you a way to
  +participate in SHCL's mechanism for controling state changes.
  +
  +`name' is a symbol that uniquely identifies the state you're trying to
  +preserve.  If you call this function twice with the same name, it will
  +replace the earlier registration with the second registration.
  +
  +`pickler' is a function that accepts no arguments.  The return value
  +is up to you, but it should be an object that represents the state
  +you're trying to protect in subshell environments.  When preserving
  +the current shell environment, SHCL will call your pickler function
  +and store the returned value.
  +
  +`unpickler' is a function that accepts two arguments: the output of
  +your pickler function and a continuation function.  Your unpickler
  +function should establish a dynamic extent where the pickled state has
  +been restored.  Then, inside that dynamic extent, your unpickler
  +should call the continuation function.
  +
  +`reclaimer' is a function that receives one argument: the output of
  +your pickler function.  When the preserved shell environment is no
  +longer needed, it must be explicitly destroyed.  When the shell
  +environment is destroyed, it will iterate through all of the pickled
  +state and call the appropriate reclaimer functions.  If your state
  +requires explicit cleanup (for example, closing files), then you
  +should perform that work in the reclaimer function.  You may safely
  +assume your preserved state will always be reclaimed exactly once.
  +
  +For example, if you wanted to preserve a special variable, you might
  +use this function like so.
  +
  +    (extend-shell-environment
  +      '*special-variable* ; name
  +      (lambda () *special-variable*)
  +      (lambda (value cont)
  +        (let ((*special-variable* value))
  +          (funcall cont)))
  +      (constantly nil))
  +
  +Note that `preserve-special-variable' will do all of the above for you
  +automatically."
     (setf (gethash name *shell-environment-handlers*)
           (make-entry :pickle pickler :unpickle unpickler :reclaim reclaimer)))
   
  
positive.code: (defparameter *special-variables-to-preserve* (fset:empty-set))
  
  (defun preserve-special-variable (symbol)
    (setf *special-variables-to-preserve* (fset:with *special-variables-to-preserve* symbol)))
  
  (defun preserve-special-variables ()
  
negative.code:       result)))
  
  (defun destroy-preserved-shell-environment (shell-environment)
    "Reclaim all the resources associated with the given preserved shell environment.
  
  It is safe to destroy a preserved shell environment multiple times.
  
  See `preserve-shell-environment'."
    (%destroy-preserved-shell-environment (preserved-environment-data shell-environment))
    (trivial-garbage:cancel-finalization shell-environment))
  
  