From f0f68b256fd3673a50f39e0f450b1a927411856f Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Mon, 22 Dec 1997 07:10:19 +0000 Subject: [PATCH] (cc-imenu-objc-function): Use bufsubst-fun as a variable, not as a function. --- lisp/progmodes/cc-menus.el | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/lisp/progmodes/cc-menus.el b/lisp/progmodes/cc-menus.el index 832b3f8fb7c..d840b744b42 100644 --- a/lisp/progmodes/cc-menus.el +++ b/lisp/progmodes/cc-menus.el @@ -279,9 +279,9 @@ Example: ;; ;; Does this emacs has buffer-substring-no-properties? ;; - (fset 'bufsubst-fun (if (fboundp 'buffer-substring-no-properties) - (symbol-function 'buffer-substring-no-properties) - (symbol-function 'buffer-substring))) + (setq bufsubst-fun (if (fboundp 'buffer-substring-no-properties) + (symbol-function 'buffer-substring-no-properties) + (symbol-function 'buffer-substring))) (goto-char (point-max)) (imenu-progress-message stupid 0) ;; @@ -293,7 +293,8 @@ Example: ((match-beginning C3) C3) ((match-beginning C2) C2) ((match-beginning C1) C1)))) - (setq str (bufsubst-fun (match-beginning langnum) (match-end langnum))) + (setq str (funcall bufsubst-fun + (match-beginning langnum) (match-end langnum))) ;; (cond ;; -- 2.39.5