   `(with-meta
      (fn [expected# & kind#]
        (vary-meta
-	 (named '~name expected#
-		(fn [actual#]
-		  ;; (prn "checking" actual# expected# kind#)
-		  (add-actual actual#
-			      (try (~checker-fn actual# expected# kind#)
-				   (catch Error ex#
-				     (tag-as-chatty-falsehood {
-							       :notes [(.getMessage ex#)]}))))))
-	 merge
-	 {:midje/chatty-checker true, :midje/checker true}))
+         (named '~name expected#
+                (fn [actual#]
+                  ;; (prn "checking" actual# expected# kind#)
+                  (add-actual actual#
+                              (try (~checker-fn actual# expected# kind#)
+                                   (catch Error ex#
+                                     (tag-as-chatty-falsehood {
+                                                               :notes [(.getMessage ex#)]}))))))
+         merge
+         {:midje/chatty-checker true, :midje/checker true}))
        {:midje/checker true}))
 
 (def contains (container-checker contains
     (fn [actual expected kind]
       (let [ [actual expected kind] (standardized-arguments actual expected kind)]
-	(cond (regex? expected)
-	      (midje-try-re expected actual re-find)
-		 
-	      :else
-	      (apply actual-x-contains? [actual expected kind]))))))
+        (cond (regex? expected)
+              (try-re expected actual re-find)
+                 
+              :else
+              (apply actual-x-contains? [actual expected kind]))))))
 
 (def just (container-checker just
     (fn [actual expected kind]
       (let [ [actual expected kind] (standardized-arguments actual expected kind)]
-	(cond (regex? expected)
-	      (midje-try-re expected actual re-matches)
-	    
-	      (same-lengths? actual expected)
-	      (apply actual-x-contains? [actual expected kind])
-
-	      :else
-	      (tag-as-chatty-falsehood
-	       {
-		:notes [(cl-format nil
-				   "Expected ~R element~:P. There ~[were~;was~:;were~]~:* ~R."
-				   (count expected)
-				   (count actual))]}))))))
+        (cond (regex? expected)
+              (try-re expected actual re-matches)
+            
+              (same-lengths? actual expected)
+              (apply actual-x-contains? [actual expected kind])
+
+              :else
+              (tag-as-chatty-falsehood
+               {
+                :notes [(cl-format nil
+                                   "Expected ~R element~:P. There ~[were~;was~:;were~]~:* ~R."
+                                   (count expected)
+                                   (count actual))]}))))))
 
 (defn- has-xfix [x-name pattern-fn take-fn]
   (fn [actual expected kind]
     (cond (set? actual)
-	  (tag-as-chatty-falsehood {
-				    :notes [(str "Sets don't have " x-name "es.")]})
-
-	  (map? actual)
-	  (tag-as-chatty-falsehood {
-				    :notes [(str "Maps don't have " x-name "es.")]})
-	  
-	  :else
-	  (let [ [actual expected kind] (standardized-arguments actual expected kind)]
-	    (cond (regex? expected)
-		  (midje-try-re (pattern-fn expected) actual re-find)
-		  
-		  (expected-fits? actual expected)
-		  (apply actual-x-contains?
-			 [(take-fn (count expected) actual) expected kind])
-
-		  :else
-		  (tag-as-chatty-falsehood
-		   {
-		    :notes [(str (cl-format nil
-					    "A collection with ~R element~:P cannot match a "
-					    (count actual))
-				 x-name
-				 (cl-format nil " of size ~R." (count expected)))]}))))))
+          (tag-as-chatty-falsehood {
+                                    :notes [(str "Sets don't have " x-name "es.")]})
+
+          (map? actual)
+          (tag-as-chatty-falsehood {
+                                    :notes [(str "Maps don't have " x-name "es.")]})
+          
+          :else
+          (let [ [actual expected kind] (standardized-arguments actual expected kind)]
+            (cond (regex? expected)
+                  (try-re (pattern-fn expected) actual re-find)
+                  
+                  (expected-fits? actual expected)
+                  (apply actual-x-contains?
+                         [(take-fn (count expected) actual) expected kind])
+
+                  :else
+                  (tag-as-chatty-falsehood
+                   {
+                    :notes [(str (cl-format nil
+                                            "A collection with ~R element~:P cannot match a "
+                                            (count actual))
+                                 x-name
+                                 (cl-format nil " of size ~R." (count expected)))]}))))))
 
 (def has-prefix
      (container-checker has-prefix

      (cond (or (empty? walking-actual) (empty? walking-expected))
            (better-of candidate best-so-far)

	    (extended-= (first walking-actual) (first walking-expected))
	    ;; actual good so far, keep working on it
	    (recur actual
	           (rest walking-actual)
		   (rest walking-expected)
		   best-so-far
		   (tack-on-to candidate
			       :actual-found (first walking-actual)
			       :expected-found (first walking-expected)))

	    (and gaps-ok? (not (empty? (rest walking-actual))))
	    ;; This is a gap in the walking actual. Skip it.
            (recur actual
	           (rest walking-actual)
		   walking-expected
		   best-so-far
                   candidate)

	    (not (empty? actual))
	    ;; See if we can find something better later on.
	    (recur (rest actual)
		   (rest actual)
		   expected
		   (better-of candidate best-so-far)
		   starting-candidate)))))

; Searches through particular types of actual results

(defn standardized-arguments [actual expected kind]
  ;; The choice to make these (throw Error) rather than be falsey is purely
  ;; one of implementation convenience.
  (cond (regex? expected)
	(cond (and (not (sequential? actual))
		   (not (empty? kind)))

(def has-suffix
     (container-checker has-suffix
      (has-xfix "suffix" #(re-pattern (str (.toString %) "$" )) take-last)))
                            
(defn has [quantifier predicate]
  (fn [actual]
    (quantifier predicate
                (if (map? actual)
                  (vals actual)
                  actual))))

;; These are used in some internal tests. Worth publicizing?
