]> code.delx.au - gnu-emacs/blobdiff - lisp/help-fns.el
Fix shr.el/image build problem
[gnu-emacs] / lisp / help-fns.el
index 97c8df2298aef6768f8a44b171852217921a24b0..e4e23330e37b0b044c53cc8dea08032722a34184 100644 (file)
@@ -571,13 +571,18 @@ FILE is the file where FUNCTION was probably defined."
                real-function))
         (aliased (or (symbolp def)
                      ;; Advised & aliased function.
-                     (and advised (symbolp real-function))))
+                     (and advised (symbolp real-function)
+                          (not (eq 'autoload (car-safe def))))
+                      (and (subrp def)
+                           (not (string= (subr-name def)
+                                         (symbol-name function))))))
         (real-def (cond
-                   (aliased (let ((f real-function))
-                              (while (and (fboundp f)
-                                          (symbolp (symbol-function f)))
-                                (setq f (symbol-function f)))
-                              f))
+                    ((and aliased (not (subrp def)))
+                     (let ((f real-function))
+                       (while (and (fboundp f)
+                                   (symbolp (symbol-function f)))
+                         (setq f (symbol-function f)))
+                       f))
                    ((subrp def) (intern (subr-name def)))
                    (t def)))
         (sig-key (if (subrp def)