Skip to content

Commit ded5ef7

Browse files
committed
Pass explicit second argument to looking-back
The second argument to looking-back is no longer optional as of Emacs 25.1.
1 parent 1be7a94 commit ded5ef7

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

rust-mode.el

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@
7777
(defun rust-rewind-irrelevant ()
7878
(let ((starting (point)))
7979
(skip-chars-backward "[:space:]\n")
80-
(if (looking-back "\\*/") (backward-char))
80+
(if (looking-back "\\*/" nil) (backward-char))
8181
(if (rust-in-str-or-cmnt)
8282
(rust-rewind-past-str-cmnt))
8383
(if (/= starting (point))
@@ -139,13 +139,13 @@
139139
;;
140140
((skip-dot-identifier
141141
(lambda ()
142-
(when (looking-back (concat "\\." rust-re-ident))
142+
(when (looking-back (concat "\\." rust-re-ident) nil)
143143
(forward-thing 'symbol -1)
144144
(backward-char)
145145
(- (current-column) rust-indent-offset)))))
146146
(cond
147147
;; foo.bar(...)
148-
((looking-back ")")
148+
((looking-back ")" nil)
149149
(backward-list 1)
150150
(funcall skip-dot-identifier))
151151

@@ -269,7 +269,7 @@
269269
;; ..or if the previous line ends with any of these:
270270
;; { ? : ( , ; [ }
271271
;; then we are at the beginning of an expression, so stay on the baseline...
272-
(looking-back "[(,:;?[{}]\\|[^|]|")
272+
(looking-back "[(,:;?[{}]\\|[^|]|" nil)
273273
;; or if the previous line is the end of an attribute, stay at the baseline...
274274
(progn (rust-rewind-to-beginning-of-current-level-expr) (looking-at "#")))))
275275
baseline
@@ -666,7 +666,7 @@ This is written mainly to be used as `end-of-defun-function' for Rust."
666666
"If the most recently inserted character is a `>`, briefly moves point to matching `<` (if any)."
667667
(interactive)
668668
(when (and rust-blink-matching-angle-brackets
669-
(looking-back ">"))
669+
(looking-back ">" nil))
670670
(let ((matching-angle-bracket-point (save-excursion
671671
(backward-char 1)
672672
(rust-find-matching-angle-bracket))))

0 commit comments

Comments
 (0)