emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master fa3af35: Allow underscore in defun-prompt-regex nam


From: Noam Postavsky
Subject: [Emacs-diffs] master fa3af35: Allow underscore in defun-prompt-regex names for sh-script
Date: Thu, 27 Jun 2019 20:10:06 -0400 (EDT)

branch: master
commit fa3af359df8754423a197682d31245ad88c02033
Author: Ola Nilsson <address@hidden>
Commit: Noam Postavsky <address@hidden>

    Allow underscore in defun-prompt-regex names for sh-script
    
    * lisp/progmodes/sh-script.el (defun-prompt-regexp):
    Allow underscore in function names.
---
 lisp/progmodes/sh-script.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
index aa6ada9..ae90531 100644
--- a/lisp/progmodes/sh-script.el
+++ b/lisp/progmodes/sh-script.el
@@ -1625,9 +1625,9 @@ with your script for an edit-interpret-debug cycle."
   (setq-local defun-prompt-regexp
               (concat
                "^\\("
-               "\\(function[ \t]\\)?[ \t]*[[:alnum:]]+[ \t]*([ \t]*)"
+               "\\(function[ \t]\\)?[ \t]*[[:alnum:]_]+[ \t]*([ \t]*)"
                "\\|"
-               "function[ \t]+[[:alnum:]]+[ \t]*\\(([ \t]*)\\)?"
+               "function[ \t]+[[:alnum:]_]+[ \t]*\\(([ \t]*)\\)?"
                "\\)[ \t]*"))
   (setq-local add-log-current-defun-function #'sh-current-defun-name)
   (add-hook 'completion-at-point-functions



reply via email to

[Prev in Thread] Current Thread [Next in Thread]