aboutsummaryrefslogtreecommitdiffstats
path: root/lib/tools
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2016-05-20 09:11:45 +0200
committerDan Gudmundsson <[email protected]>2016-05-23 14:46:27 +0200
commit8e91ce7cde8b426354f3adcedefc3ce9ffb40117 (patch)
treed1f462a5fbb4de5062b32abb75377e7a43ef3f4a /lib/tools
parente20a1671da3338517e6795165c2a07bc2154c620 (diff)
downloadotp-8e91ce7cde8b426354f3adcedefc3ce9ffb40117.tar.gz
otp-8e91ce7cde8b426354f3adcedefc3ce9ffb40117.tar.bz2
otp-8e91ce7cde8b426354f3adcedefc3ce9ffb40117.zip
emacs: Improve default tag search
Add current module to non external functions calls. Also improves finding record and macro definitions.
Diffstat (limited to 'lib/tools')
-rw-r--r--lib/tools/emacs/erlang.el6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/tools/emacs/erlang.el b/lib/tools/emacs/erlang.el
index b808987e6e..3d20d86f43 100644
--- a/lib/tools/emacs/erlang.el
+++ b/lib/tools/emacs/erlang.el
@@ -3760,6 +3760,12 @@ In the future the list may contain more elements."
(if (assoc fk (cdr (car imports)))
(setq mod (car (car imports)))
(setq imports (cdr imports))))
+ (cond ((eq (preceding-char) ?#)
+ (setq fk (concat "-record(" fk)))
+ ((eq (preceding-char) ??)
+ (setq fk (concat "-define(" fk)))
+ ((and (null mod) (not (member fk erlang-int-bifs)))
+ (setq mod (erlang-get-module))))
(setq res (list mod fk)))))
(store-match-data md)
res)))