summaryrefslogtreecommitdiff
path: root/lisp/progmodes/octave.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/progmodes/octave.el')
-rw-r--r--lisp/progmodes/octave.el14
1 files changed, 7 insertions, 7 deletions
diff --git a/lisp/progmodes/octave.el b/lisp/progmodes/octave.el
index aff3066c698..79530f81673 100644
--- a/lisp/progmodes/octave.el
+++ b/lisp/progmodes/octave.el
@@ -351,7 +351,7 @@ Non-nil means always go to the next Octave code line after sending."
;; corresponding continuation lines).
(defun octave-smie--funcall-p ()
- "Return non-nil if we're in an expression context. Moves point."
+ "Return non-nil if we're in an expression context. Move point."
(looking-at "[ \t]*("))
(defun octave-smie--end-index-p ()
@@ -895,7 +895,7 @@ startup file, `~/.emacs-octave'."
(defun inferior-octave-completion-at-point ()
"Return the data to complete the Octave symbol at point."
;; https://debbugs.gnu.org/14300
- (unless (string-match-p "/" (or (comint--match-partial-filename) ""))
+ (unless (string-search "/" (or (comint--match-partial-filename) ""))
(let ((beg (save-excursion
(skip-syntax-backward "w_" (comint-line-beginning-position))
(point)))
@@ -1034,7 +1034,7 @@ directory and makes this the current buffer's default directory."
(nth 8 (syntax-ppss)))
(defun octave-looking-at-kw (regexp)
- "Like `looking-at', but sets `case-fold-search' nil."
+ "Like `looking-at', but set `case-fold-search' nil first."
(let ((case-fold-search nil))
(looking-at regexp)))
@@ -1814,18 +1814,18 @@ If the environment variable OCTAVE_SRCDIR is set, it is searched first."
(user-error "Aborted")))
(_ name)))
-(defvar find-tag-marker-ring)
+(declare-function xref-push-marker-stack "xref" (&optional m))
(defun octave-find-definition (fn)
"Find the definition of FN.
Functions implemented in C++ can be found if
variable `octave-source-directories' is set correctly."
(interactive (list (octave-completing-read)))
- (require 'etags)
+ (require 'xref)
(let ((orig (point)))
(if (and (derived-mode-p 'octave-mode)
(octave-goto-function-definition fn))
- (ring-insert find-tag-marker-ring (copy-marker orig))
+ (xref-push-marker-stack (copy-marker orig))
(inferior-octave-send-list-and-digest
;; help NAME is more verbose
(list (format "\
@@ -1840,7 +1840,7 @@ if iskeyword('%s') disp('`%s'' is a keyword') else which('%s') endif\n"
(setq file (match-string 1 line))))
(if (not file)
(user-error "%s" (or line (format-message "`%s' not found" fn)))
- (ring-insert find-tag-marker-ring (point-marker))
+ (xref-push-marker-stack)
(setq file (funcall octave-find-definition-filename-function file))
(when file
(find-file file)