[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 4b83e7d: Fdocumentation_property: Return doc string
From: |
Lars Ingebrigtsen |
Subject: |
[Emacs-diffs] master 4b83e7d: Fdocumentation_property: Return doc string for indirect variables |
Date: |
Wed, 26 Jun 2019 10:26:16 -0400 (EDT) |
branch: master
commit 4b83e7d016ba8e9983c6fd0e154bfa9e22481958
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>
Fdocumentation_property: Return doc string for indirect variables
* src/doc.c (Fdocumentation_property): When dealing with indirect
variables (i.e., aliases), also check the symbol being pointed to
for the doc string (bug #17180).
---
src/doc.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/src/doc.c b/src/doc.c
index 3fa0eaa..bc05d09 100644
--- a/src/doc.c
+++ b/src/doc.c
@@ -436,8 +436,20 @@ aren't strings. */)
documentation_property:
tem = Fget (symbol, prop);
+
+ /* If we don't have any documentation for this symbol, try to see whether
+ it's an indirect variable and get the documentation from there instead. */
+ if (NILP (tem))
+ {
+ Lisp_Object indirect = Findirect_variable (symbol);
+ if (!NILP (indirect))
+ tem = Fget (indirect, prop);
+ }
+
if (EQ (tem, make_fixnum (0)))
tem = Qnil;
+
+ /* See if we want to look for the string in the DOC file. */
if (FIXNUMP (tem) || (CONSP (tem) && FIXNUMP (XCDR (tem))))
{
Lisp_Object doc = tem;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master 4b83e7d: Fdocumentation_property: Return doc string for indirect variables,
Lars Ingebrigtsen <=