diff options
author | Jose Antonio Ortega Ruiz <jao@gnu.org> | 2009-02-12 22:47:34 +0100 |
---|---|---|
committer | Jose Antonio Ortega Ruiz <jao@gnu.org> | 2009-02-12 22:47:34 +0100 |
commit | 09c532a18d33ab2e0a3dcb3a38e746992e3381aa (patch) | |
tree | 8501dc3786cdaa06d7f11e346e23a7d5c2fe5692 | |
parent | fa17e0cb3367e68e8db386497ddcfe3cfcf96416 (diff) | |
download | geiser-chez-09c532a18d33ab2e0a3dcb3a38e746992e3381aa.tar.gz geiser-chez-09c532a18d33ab2e0a3dcb3a38e746992e3381aa.tar.bz2 |
Faster M-.
-rw-r--r-- | elisp/geiser-edit.el | 7 | ||||
-rw-r--r-- | scheme/guile/geiser/introspection.scm | 6 |
2 files changed, 6 insertions, 7 deletions
diff --git a/elisp/geiser-edit.el b/elisp/geiser-edit.el index d51246f..3a5618a 100644 --- a/elisp/geiser-edit.el +++ b/elisp/geiser-edit.el @@ -60,7 +60,7 @@ (cdr (assoc 'line loc))) (defconst geiser-edit--def-re - (regexp-opt '("define" "defmacro" "define-macro" "define-syntax"))) + (regexp-opt '("define" "defmacro" "define-macro" "define-syntax" "define*"))) (defsubst geiser-edit--def-re (symbol) (format "(%s +(?%s" geiser-edit--def-re symbol)) @@ -69,8 +69,9 @@ (if (numberp line) (goto-line line) (goto-char (point-min)) - (when (re-search-forward (geiser-edit--def-re symbol) nil t) - (beginning-of-line)))) + (when (or (re-search-forward (geiser-edit--def-re symbol) nil t) + (re-search-forward (format "\\_<%s\\_>" symbol) nil t)) + (goto-char (match-beginning 0))))) (defun geiser-edit--try-edit (symbol ret) (let* ((loc (geiser-eval--retort-result ret)) diff --git a/scheme/guile/geiser/introspection.scm b/scheme/guile/geiser/introspection.scm index 136ada3..7fce4c9 100644 --- a/scheme/guile/geiser/introspection.scm +++ b/scheme/guile/geiser/introspection.scm @@ -112,9 +112,7 @@ (make-location (module-filename name) #f)) (define (symbol-location sym) - (let ((prog (resolve-symbol sym))) - (cond ((program? prog) (program-location prog)) - ((symbol-module sym) => make-location-from-module-name) - (else '())))) + (cond ((symbol-module sym) => make-location-from-module-name) + (else '()))) ;;; introspection.scm ends here |