Skip to content

Commit

Permalink
auto merge of #13922 : Rufflewind/rust/patch-1, r=pnkfelix
Browse files Browse the repository at this point in the history
Since rust-top-item-beg-re hasn't been defined yet, using defvar instead of
setq is more appropriate here (and also silences compilation warnings).
  • Loading branch information
bors committed May 12, 2014
2 parents 0550b79 + 77c56f7 commit edae0bd
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/etc/emacs/rust-mode.el
Original file line number Diff line number Diff line change
Expand Up @@ -380,11 +380,11 @@ idomenu (imenu with `ido-mode') for best mileage.")
;;; Defun Motions

;;; Start of a Rust item
(setq rust-top-item-beg-re
(concat "^\\s-*\\(?:priv\\|pub\\)?\\s-*"
(regexp-opt
'("enum" "struct" "type" "mod" "use" "fn" "static" "impl"
"extern" "impl" "static" "trait"))))
(defvar rust-top-item-beg-re
(concat "^\\s-*\\(?:priv\\|pub\\)?\\s-*"
(regexp-opt
'("enum" "struct" "type" "mod" "use" "fn" "static" "impl"
"extern" "impl" "static" "trait"))))

(defun rust-beginning-of-defun (&optional arg)
"Move backward to the beginning of the current defun.
Expand Down

0 comments on commit edae0bd

Please sign in to comment.