       (beginning-of-line)
       (slate-forward-whitespace)
       (when (looking-at "[A-Za-z][A-Za-z0-9]*:") ;indent for colon
-	(let ((parse-sexp-ignore-comments t))
-	  (beginning-of-line)
-	  (slate-backward-whitespace)
-	  (unless (memq (preceding-char) '(?. ?| ?\[ ?\( ?\{))
-	    (setq is-keyword t)))))
+    (let ((parse-sexp-ignore-comments t))
+      (beginning-of-line)
+      (slate-backward-whitespace)
+      (unless (memq (preceding-char) '(?. ?| ?\[ ?\( ?\{))
+        (setq is-keyword t)))))
       (setq indent-amount (slate-calculate-indent))
       (slate-indent-to-column indent-amount)))
 

  (let (state)
    (setq state (parse-partial-sexp (point-min) (point)))
    (and (nth 3 state)
	 (char-to-string (nth 3 state)))))

(defun slate-white-to-bolp ()
  "Returns T if from the current position to beginning of line is whitespace."
  (let (done is-white line-start-pos)
    (save-excursion
      (save-excursion
	(beginning-of-line)
	(setq line-start-pos (point)))
      (while (not done)
	(unless (bolp)
	  (skip-chars-backward " \t"))
	(cond ((bolp)
	       (setq done t)
	       (setq is-white t))
	      ((equal (char-after (1- (point))) ?\")
	       (backward-sexp)
	       (when (< (point) line-start-pos) ;comment is multi line
		 (setq done t)))
	      (t
	       (setq done t))))
      is-white)))

(defun slate-backward-comment ()
  "Moves to the beginning of the containing comment, or
the end of the previous one if not in a comment."
  (search-backward "\"")		;find its start
  (while (equal (preceding-char) ?\\)	;skip over escaped ones
    (backward-char 1)
    (search-backward "\"")))


selector."
  (let (start ch)
    (when (equal (preceding-char) ?.) ; if we start at eos
      (backward-char 1))          ; we find the begin of THAT stmt
    (while (and (null start) (not (bobp)))
      (slate-backward-whitespace)
      (setq ch (preceding-char))
      (cond ((equal ch ?.)
         (let (saved-point)
           (setq saved-point (point))
           (slate-forward-whitespace)
           (if (slate-white-to-bolp)
           (setq start (point))
         (goto-char saved-point)
         (slate-backward-sexp 1))))
        ((equal ch ?^)     ; HACK -- presuming that when we back
                    ;up into a return that we're at the
                    ;start of a statement
         (backward-char 1)
         (setq start (point)))
        ((equal ch ?\[)
         (if (> (current-column) 1)
         (setq start (point))
           (forward-line 1)
           (beginning-of-line)
           (slate-forward-whitespace)
           (setq start (point))))
        ((equal ch ?\{)
         (setq start (point)))
        ((equal ch ?\()
         (backward-char 1))
        ((equal ch ?|)
         (backward-char 1)
         (skip-chars-backward "^[")
         (slate-backward-whitespace))
        (t
         (slate-backward-sexp 1))))
    (unless start
      (goto-char (point-min))
      (slate-forward-whitespace)
