]> git.eshelyaron.com Git - emacs.git/commitdiff
(describe-variable): Mention if the variable is an alias.
authorPavel Janík <Pavel@Janik.cz>
Fri, 12 Jul 2002 08:58:32 +0000 (08:58 +0000)
committerPavel Janík <Pavel@Janik.cz>
Fri, 12 Jul 2002 08:58:32 +0000 (08:58 +0000)
lisp/ChangeLog
lisp/help-fns.el

index 106896ddb2c94754f3a3b70d3f3593c696fa7576..d53059efb6bea902ccbeb7e815201bf9bf978cce 100644 (file)
@@ -1,3 +1,8 @@
+2002-07-12  John Paul Wallington  <jpw@shootybangbang.com>
+
+       * help-fns.el (describe-variable): Mention if the variable is an
+       alias.
+
 2002-07-12  Kenichi Handa  <handa@etl.go.jp>
 
        * international/mule-cmds.el (locale-language-names): Change "mk"
index f62443ef152e6fcf2db9794460156b4a75753981..d4daa2fa11c265b4d00ff8ae3db7fc4901839cdd 100644 (file)
@@ -438,7 +438,16 @@ it is displayed along with the global value."
                (terpri)))
            (let ((doc (documentation-property variable 'variable-documentation)))
              (princ (or doc "Not documented as a variable.")))
-         
+           
+           ;; Mention if the variable is an alias.
+           (let ((alias (condition-case nil
+                            (indirect-variable variable)
+                          (error variable))))
+             (unless (eq alias variable)
+               (terpri)
+               (terpri)
+               (princ (format "This variable is an alias for `%s'." alias))))
+           
            ;; Make a link to customize if this variable can be customized.
            ;; Note, it is not reliable to test only for a custom-type property
            ;; because those are only present after the var's definition