anchor.diff:    (or (soft-word-boundary-p thing)
         (hard-word-boundary-p thing)))
   
  +(defgeneric to-string (thing))
  +(defmethod to-string ((thing string))
  +  thing)
  +(defmethod to-string ((thing simple-word))
  +  (simple-word-text thing))
  +(defmethod to-string ((thing token))
  +  nil)
  +
   (defparameter *aliases* (fset:empty-map))
   
   (defstruct alias
  
positive.code:     (fset:do-seq (f fragments)
        (write-string (string-fragment-string f) stream))
      (get-output-stream-string stream)))
  
  (defun expand-assignment-word (assignment-word)
    (let ((value (assignment-word-value-word assignment-word)))
      (expansion-for value )))
  
  (defgeneric expand (thing))
  
  
negative.code: 
  (defun set-alias (name words &key continue-expansion)
    (setf (fset:lookup *aliases* name)
          (make-alias :words (fset:image #'to-string (fset:convert 'fset:seq words))
                      :continue-expansion continue-expansion))
    nil)
  
  (defun unalias (name)
    (setf *aliases* (fset:less *aliases* name)))
  
  (defun expand-aliases (tokens)
    (unless (typep tokens 'fset:seq)
      (setf tokens (fset:convert 'fset:seq tokens)))
  
    (let* ((remaining tokens)
           (*aliases* *aliases*))
      (labels
          ((finish ()
             (return-from expand-aliases remaining))
           (alias-for (string)
             (unless string
               (return-from alias-for))
             (fset:lookup *aliases* string))
           (next-word ()
             (to-string (fset:first remaining))))
        (loop
           (when (zerop (fset:size remaining))
             (finish))
  
           (let* ((next-word (to-string (next-word)))
                  (alias (alias-for next-word)))
             (unless alias
               (finish))
  
             (setf *aliases* (fset:less *aliases* next-word))
  
             (let ((less-first (fset:less-first remaining)))
               (when (alias-continue-expansion alias)
                 (setf less-first (expand-aliases less-first)))
               (setf remaining (fset:concat (alias-words alias) less-first))))))))
  
  (defun expansion-for-words (things &key expand-aliases expand-pathname (split-fields t))
    (declare (ignore expand-pathname))
    (setf things (fset:convert 'fset:seq things))
    (when (equal 0 (fset:size things))
      (return-from expansion-for-words #()))
  
    (let* ((*split-fields* split-fields)
           (result (fset:empty-seq))
           (seqs (if expand-aliases
                     (expand-aliases things)
                     things))
           next-word)
  
      (setf seqs (fset:image #'expand seqs))
      (fset:prependf seqs (fset:image (lambda (x) (fset:seq x)) pre-seqs))
      (labels
          ((observe (fragment)
             (unless next-word
               (setf next-word (fset:empty-seq)))
             (fset:push-last next-word fragment))
           (boundary (value)
             (when (and (not next-word) (soft-word-boundary-p value))
               (return-from boundary))
             (when (not next-word)
               (observe (make-string-fragment "")))
  
             (fset:push-last result next-word)
             (setf next-word nil)))
        (fset:do-seq (sub-seq seqs)
          (fset:do-seq (fragment sub-seq)
            (if (word-boundary-p fragment)
                (boundary fragment)
                (observe fragment)))
          (boundary +soft-word-boundary+)))
  
      result))
  
  (defun expand-pathname (fragments)
    )
  