anchor.diff:       (sdl2:with-event-loop (:method :poll)
          (:keydown
           (:keysym keysym)
  -        (let ((scancode (sdl2:scancode-value keysym)))
  -          (setf ,keydown-scancodes (adjoin scancode ,keydown-scancodes))))
  +        (setf ,keydown-scancodes (keydown-actions ,keydown-scancodes (sdl2:scancode-value keysym))))
   
          (:keyup
           (:keysym keysym)
  -        (let ((scancode (sdl2:scancode-value keysym)))
  -          (if (member scancode ,keydown-scancodes)
  -              (setf ,keydown-scancodes (set-difference ,keydown-scancodes (list scancode))))
  -          (when (sdl2:scancode= scancode :scancode-escape)
  -            (sdl2:push-event :quit))))
  +        (setf ,keydown-scancodes (keyup-actions ,keydown-scancodes (sdl2:scancode-value keysym))))
   
          (:idle
           ()
  
positive.code:        (:quit
          ()
          t))))
  
  ;;;; OpenGL
  ;;; This section hides the C-like OpenGL code. It is still very easy
  
negative.code:   `(sdl2:with-init (:everything)
       (sdl2:with-window (,window :title ,title :w ,width :h ,height :flags '(:shown :opengl))
         (sdl2:with-gl-context (gl-context ,window)
           (setup-sdl2-and-gl ,window gl-context ,fullscreen)
           ,@body))))
  
  (defmacro with-game-loop ((window keydown-scancodes) &body body)
  