From: Leo Liu Date: Fri, 6 Dec 2013 04:26:17 +0000 (+0800) Subject: * progmodes/octave.el (inferior-octave-prompt): Use shy groups. X-Git-Tag: emacs-24.3.90~173^2^2~42^2~45^2~387^2~542 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=b2856a6f7cbd625e195b5bfb7a87925ebc4c22f8;p=emacs.git * progmodes/octave.el (inferior-octave-prompt): Use shy groups. (inferior-octave-startup): Always use "octave> " for prompt. (octave-goto-function-definition) (octave-sync-function-file-names) (octave-find-definition-default-filename): Remove redundant backquotes. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3877d053199..3bd389d93d0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2013-12-06 Leo Liu + + * progmodes/octave.el (inferior-octave-prompt): Use shy groups. + (inferior-octave-startup): Always use "octave> " for prompt. + (octave-goto-function-definition) + (octave-sync-function-file-names) + (octave-find-definition-default-filename): Remove redundant backquotes. + 2013-12-06 Dmitry Gutov * progmodes/ruby-mode.el (ruby-mode-syntax-table): Don't modify diff --git a/lisp/progmodes/octave.el b/lisp/progmodes/octave.el index 4246b46e238..778659c0de4 100644 --- a/lisp/progmodes/octave.el +++ b/lisp/progmodes/octave.el @@ -444,7 +444,7 @@ Non-nil means always go to the next Octave code line after sending." "unwind_protect_cleanup") (smie-rule-parent octave-block-offset) ;; For (invalid) code between switch and case. - ;; (if (smie-parent-p "switch") 4) + ;; (if (smie-rule-parent-p "switch") 4) nil)))) (defun octave-indent-comment () @@ -599,7 +599,9 @@ definitions can also be stored in files and used in batch mode." :group 'octave) (defcustom inferior-octave-prompt - "\\(^octave\\(\\|.bin\\|.exe\\|-gui\\)\\(-[.0-9]+\\)?\\(:[0-9]+\\)?\\|^debug\\|^\\)>+ " + ;; For Octave >= 3.8, default is always 'octave', see + ;; http://hg.savannah.gnu.org/hgweb/octave/rev/708173343c50 + "\\(?:^octave\\(?:.bin\\|.exe\\)?\\(?:-[.0-9]+\\)?\\(?::[0-9]+\\)?\\|^debug\\|^\\)>+ " "Regexp to match prompts for the inferior Octave process." :type 'regexp :group 'octave) @@ -821,7 +823,8 @@ startup file, `~/.emacs-octave'." (inferior-octave-send-list-and-digest (list "more off;\n" (unless (equal inferior-octave-output-string ">> ") - "PS1 ('\\s> ');\n") + ;; See http://hg.savannah.gnu.org/hgweb/octave/rev/708173343c50 + "PS1 ('octave> ');\n") (when (and inferior-octave-startup-file (file-exists-p inferior-octave-startup-file)) (format "source ('%s');\n" inferior-octave-startup-file)))) @@ -1030,8 +1033,8 @@ directory and makes this the current buffer's default directory." (unless found (goto-char orig)) found)))) (pcase (and buffer-file-name (file-name-extension buffer-file-name)) - (`"cc" (funcall search - "\\_