   (merlin-seek point))
 
 (defun merlin-update-lock-zone-display ()
-  "Updates the locked zone display, according to `merlin-display-lock-zone', ie.
- iterates through it and call each method"
-  (mapc
-   '(lambda (x)
-      (case x
-        (margin (merlin-update-margin-lock-zone))
-        (highlight (merlin-update-highlight-lock-zone))))
-   merlin-display-lock-zone))
+  "Update the locked zone display, according to `merlin-display-lock-zone', ie.
+ iterates through it and call each method."
+  (dolist (x merlin-display-lock-zone)
+    (case x
+      (margin (merlin-update-margin-lock-zone))
+      (highlight (merlin-update-highlight-lock-zone)))))
 
 
 (defun merlin-update-margin-lock-zone ()

  (add-hook 'kill-buffer-hook 'merlin-kill-buffer-hook))
                                      
(defun merlin-kill-all-processes ()
  "Kill all the remaining buffers containing merlin processes"
  (interactive)
  (mapc '(lambda (p)
           (with-current-buffer (process-buffer p)
             (merlin-kill-process)))))

(provide 'merlin)

  (string-match "^Warning" msg))

(defun merlin-display-errors-in-margin (errors)
  "Given a list of ERRORS, put annotations in the margin corresponding to them."
  (merlin-delete-error-overlays)
  (setq merlin-pending-errors (append errors nil))
  (setq merlin-pending-errors-overlays 
        (mapcar (lambda (err)
                  (let ((overlay (make-overlay
                                  (merlin-make-point (cdr (assoc 'start err)))
                                  (merlin-make-point (cdr (assoc 'end err))))))
                    (if (merlin-warning-p (cdr (assoc 'message err)))
                        (merlin-put-margin-overlay overlay "?" compilation-warning-face)
                      (merlin-put-margin-overlay overlay "!" compilation-error-face))
                     
                    overlay)) 
                errors))
  (message "(pending errors, use %s to jump)"
           (substitute-command-keys "\\[merlin-next-error]")))

