From 66943d0c9cbb0cca33e1fc88a09af14b6abf45dd Mon Sep 17 00:00:00 2001 From: Dmitry Gutov Date: Mon, 11 Mar 2019 02:30:08 +0200 Subject: [PATCH] (ruby-add-log-current-method): Recognize methods ending with ? or ! * lisp/progmodes/ruby-mode.el (ruby-add-log-current-method): Recognize method names ending with ? or !. --- lisp/progmodes/ruby-mode.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/progmodes/ruby-mode.el b/lisp/progmodes/ruby-mode.el index e575d6cc16c..707875d130d 100644 --- a/lisp/progmodes/ruby-mode.el +++ b/lisp/progmodes/ruby-mode.el @@ -1614,7 +1614,7 @@ See `add-log-current-defun-function'." (concat "^[ \t]*" re "[ \t]+" "\\(" ;; \\. and :: for class methods - "\\([A-Za-z_]" ruby-symbol-re "*\\|\\.\\|::" "\\)" + "\\([A-Za-z_]" ruby-symbol-re "*[?!]?\\|\\.\\|::" "\\)" "+\\)"))) (definition-re (funcall make-definition-re ruby-defun-beg-re)) (module-re (funcall make-definition-re "\\(class\\|module\\)"))) -- 2.39.2