     (if successp (midje-after-compilation-check-fact))))
 
 (defun midje-after-compilation-check-fact ()
-  (slime-eval-async `(swank:eval-and-grab-output ,last-checked-midje-fact)
-    'midje-insert-below-code-under-test))
-
+  (if midje-running-fact
+      (slime-eval-async `(swank:eval-and-grab-output ,last-checked-midje-fact)
+	'midje-insert-below-code-under-test))
+  (setq midje-running-fact nil))
 
 (defun midje-check-fact ()
   "If on or near a Midje fact, check it with


  (interactive)
  (midje-clear-comments)
  (slime-compile-defun)
  ; Callback is slime-compilation-finished, then midje-after-compilation-check-fact
)


(require 'clojure-mode)
(require 'slime)
(require 'newcomment)

(defvar midje-running-fact nil)   ;; KLUDGE!

(defvar midje-comments ";.;.")
(defvar last-checked-midje-fact nil)
