anchor.diff:  	  (logand (register word) #x00ff)))))
   
   (defsetf byte-register (reg) (value)
  +  "Write to a byte register."
     `(let* ((register-to-word (getf +byte-register-to-word+ ,reg)) (word (first register-to-word)) (wrapped-value (wrap-carry ,value nil)))
        (if (second register-to-word)
   	 (setf (register word) (+ (ash wrapped-value 8) (logand (register word) #x00ff)))
  
positive.code: (defparameter *disasm* nil "Whether to disassemble")
  
  (defmacro disasm-instr (on-disasm &body body)
    `(if *disasm*
         ,on-disasm
         (progn ,@body)))
  
negative.code: ;;; Convenience functions
  
  (defun negative-p (value is-word)
    "Determine whether a number is negative (has its sign bit set)."
    (let ((sign-and (if is-word #x8000 #x80)))
      (= (logand sign-and value) sign-and)))
  
  (defun twos-complement (value is-word)
    "Calculate the value of a number using two's complement."
    (if (negative-p value is-word)
        (- (1+ (logxor value (if is-word #xffff #xff))))
        value))
  