;;; help-fns.el --- Complex help functions -*- lexical-binding: t -*-
-;; Copyright (C) 1985-1986, 1993-1994, 1998-2012
-;; Free Software Foundation, Inc.
+;; Copyright (C) 1985-1986, 1993-1994, 1998-2013 Free Software
+;; Foundation, Inc.
;; Maintainer: FSF
;; Keywords: help, internal
(point)))
(terpri)(terpri)
- (let* ((doc-raw (condition-case err
- (documentation function t)
- (error (format "No Doc! %S" err))))
+ (let* ((doc-raw (documentation function t))
;; If the function is autoloaded, and its docstring has
;; key substitution constructs, load the library.
(doc (progn
- (and (autoloadp real-def)
+ (and (autoloadp real-def) doc-raw
help-enable-auto-load
(string-match "\\([^\\]=\\|[^=]\\|\\`\\)\\\\[[{<]"
doc-raw)
(cond
((bufferp locus)
(princ (format "Local in buffer %s; "
- (buffer-name))))
+ (buffer-name buffer))))
((framep locus)
(princ (format "It is a frame-local variable; ")))
((terminal-live-p locus)
(obsolete (get variable 'byte-obsolete-variable))
(use (car obsolete))
(safe-var (get variable 'safe-local-variable))
- (doc (condition-case err
- (or (documentation-property
- variable 'variable-documentation)
- (documentation-property
- alias 'variable-documentation))
- (error (format "Doc not found: %S" err))))
+ (doc (or (documentation-property
+ variable 'variable-documentation)
+ (documentation-property
+ alias 'variable-documentation)))
(extra-line nil))
;; Mention if it's a local variable.