   (set (make-local-variable 'indent-tabs-mode) nil)
 
   ;; Allow paragraph fills for comments
-  (set (make-local-variable 'comment-start-skip) 
+  (set (make-local-variable 'comment-start-skip)
        "\\(?://[/!]*\\|/\\*[*!]?\\)[[:space:]]*")
   (set (make-local-variable 'paragraph-start)
        (concat "[[:space:]]*\\(?:" comment-start-skip "\\|\\*/?[[:space:]]*\\|\\)$"))

  (set (make-local-variable 'adaptive-fill-function) 'rust-find-fill-prefix)
  (set (make-local-variable 'comment-multi-line) t)
  (set (make-local-variable 'comment-line-break-function) 'rust-comment-indent-new-line)
  )



  (rust-with-comment-fill-prefix
   (lambda () (comment-indent-new-line arg))))

;;; Imenu support
(defvar rust-imenu-generic-expression
  (append (loop for item in
                '("enum" "struct" "type" "mod" "fn")
                collect `(nil ,(rust-re-item-def item) 1))
          `(("Impl" ,(rust-re-item-def "impl") 1)))
  "Value for `imenu-generic-expression' in Rust mode.

Create a flat index of the item definitions in a Rust file.

Imenu will show all the enums, structs, etc. at the same level.
Implementations will be shown under the `Impl` subheading.
Use idomenu (imenu with ido-mode) for best mileage.")

;; For compatibility with Emacs < 24, derive conditionally
(defalias 'rust-parent-mode
  (if (fboundp 'prog-mode) 'prog-mode 'fundamental-mode))
