diff options
author | Brad King <brad.king@kitware.com> | 2015-01-19 14:59:14 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2015-01-19 14:59:14 (GMT) |
commit | bc9cd21bd46023f3f0f7be5be5386315a193af08 (patch) | |
tree | 8339ca6f1fcde1436307150f255210a9884f44e1 | |
parent | a2dc7f87e01c3621878e3e2336d50c769524572a (diff) | |
parent | ca80598ecaff14414193fd65268f80e1eddb9fa0 (diff) | |
download | CMake-bc9cd21bd46023f3f0f7be5be5386315a193af08.zip CMake-bc9cd21bd46023f3f0f7be5be5386315a193af08.tar.gz CMake-bc9cd21bd46023f3f0f7be5be5386315a193af08.tar.bz2 |
Merge branch 'emacs-mode-fix-word-at-point' into release
-rw-r--r-- | Auxiliary/cmake-mode.el | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/Auxiliary/cmake-mode.el b/Auxiliary/cmake-mode.el index f1470f3..37ca942 100644 --- a/Auxiliary/cmake-mode.el +++ b/Auxiliary/cmake-mode.el @@ -320,9 +320,13 @@ and store the result as a list in LISTVAR." )) ) -(require 'thingatpt) +(defun cmake-symbol-at-point () + (let ((symbol (symbol-at-point))) + (and (not (null symbol)) + (symbol-name symbol)))) + (defun cmake-help-type (type) - (let* ((default-entry (word-at-point)) + (let* ((default-entry (cmake-symbol-at-point)) (history (car (cdr (cdr (assoc type cmake-string-to-list-symbol))))) (input (completing-read (format "CMake %s: " type) ; prompt @@ -365,7 +369,7 @@ and store the result as a list in LISTVAR." (defun cmake-help () "Queries for any of the four available help topics and prints out the approriate page." (interactive) - (let* ((default-entry (word-at-point)) + (let* ((default-entry (cmake-symbol-at-point)) (command-list (cmake-get-list "command")) (variable-list (cmake-get-list "variable")) (module-list (cmake-get-list "module")) |