From e8974c48ae2f265555c7772ea0989fca5e4158b8 Mon Sep 17 00:00:00 2001 From: Drew Adams Date: Fri, 25 Mar 2011 00:38:12 +0800 Subject: [PATCH] Add support for defun in thingatpt.el --- lisp/ChangeLog | 4 ++++ lisp/thingatpt.el | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index af2d4ee5a8e..5d6b203aea2 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2011-03-24 Drew Adams + + * thingatpt.el: Support `defun'. + 2011-03-23 Leo Liu * abbrevlist.el: Move to obsolete/abbrevlist.el. diff --git a/lisp/thingatpt.el b/lisp/thingatpt.el index 020faa197cd..a56c3e4d501 100644 --- a/lisp/thingatpt.el +++ b/lisp/thingatpt.el @@ -207,6 +207,12 @@ a symbol as a valid THING." (cons opoint end)))) (error nil))))) +;; Defuns + +(put 'defun 'beginning-op 'beginning-of-defun) +(put 'defun 'end-op 'end-of-defun) +(put 'defun 'forward-op 'end-of-defun) + ;; Filenames and URLs www.com/foo%32bar (defvar thing-at-point-file-name-chars "-~/[:alnum:]_.${}#%,:" -- 2.39.5