anchor.diff:  ;; the actual packing/unpacking is done by some special code in the closures
   ;; generated by %define-packet-type. There MUST be a better way of doing it!!!
   (define-alias :string :uint8)
  +(define-alias :wstring :uint16)
   
   ;; it'd be nicer if we could just define :string as a packet type, but this isn't possible.
   ;; maybe we need to be able to define array types?
  
positive.code: 			(if (zerop code)
  				(return-from extract-string)
  				(princ (code-char code) s))))))))
  
  ;; --------------------- packets / structures --------------------------
  
  
negative.code:     (destructuring-bind (slot-name slot-type arrayp length offset) slot
        (let ((value (slot-value object slot-name)))
  		(cond
  		  ((null value)
  		   ;; ignore arrays given as nil, this means an empty array
  		   nil)
  		  ((not arrayp)
  		   (pack-type value slot-type buffer (+ start offset)))
  		  ((eq slot-type :string)
  		   ;; special case handling for strings. there must be a better way of doing this!!!
  		   (if (stringp value)
  			   (pack-string value length buffer (+ start offset))
  			   (error "Value ~S is not of type STRING for slot ~S." value slot-name)))
  		  ((eq slot-type :wstring)
  		   ;; special case handling for strings. there must be a better way of doing this!!!
  		   (if (stringp value)
  			   (pack-wstring value length buffer (+ start offset))
  			   (error "Value ~S is not of type STRING for slot ~S." value slot-name)))
  		  ((> (length value) length)
  		   (error "Array for slot ~S is too large" slot-name))
  