mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-11 16:08:13 +00:00
* lisp/abbrev.el (define-abbrev): Beware new meaning of fboundp.
* lisp/emacs-lisp/elint.el (elint-find-builtins): * lisp/emacs-lisp/eldoc.el (eldoc-symbol-function): * lisp/emacs-lisp/bytecomp.el (byte-compile-callargs-warn) (byte-compile-file-form-defmumble, byte-compile, byte-compile-form): * lisp/emacs-lisp/byte-opt.el (byte-compile-inline-expand): * lisp/apropos.el (apropos-safe-documentation): * lisp/subr.el (symbol-file): Remove redundant fboundp. * lisp/progmodes/idlw-shell.el (idlwave-shell-comint-filter): Use defalias.
This commit is contained in:
parent
daccca97f0
commit
6bdd920482
@ -1,3 +1,15 @@
|
||||
2014-01-06 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* abbrev.el (define-abbrev): Beware new meaning of fboundp.
|
||||
* emacs-lisp/elint.el (elint-find-builtins):
|
||||
* emacs-lisp/eldoc.el (eldoc-symbol-function):
|
||||
* emacs-lisp/bytecomp.el (byte-compile-callargs-warn)
|
||||
(byte-compile-file-form-defmumble, byte-compile, byte-compile-form):
|
||||
* emacs-lisp/byte-opt.el (byte-compile-inline-expand):
|
||||
* apropos.el (apropos-safe-documentation):
|
||||
* subr.el (symbol-file): Remove redundant fboundp.
|
||||
* progmodes/idlw-shell.el (idlwave-shell-comint-filter): Use defalias.
|
||||
|
||||
2014-01-06 Bastien Guerry <bzg@gnu.org>
|
||||
|
||||
* hl-line.el (global-hl-line-overlay): Make a local variable.
|
||||
|
@ -588,7 +588,7 @@ An obsolete but still supported calling form is:
|
||||
(boundp sym) (symbol-value sym)
|
||||
(not (abbrev-get sym :system)))
|
||||
(unless (or system-flag
|
||||
(and (boundp sym) (fboundp sym)
|
||||
(and (boundp sym)
|
||||
;; load-file-name
|
||||
(equal (symbol-value sym) expansion)
|
||||
(equal (symbol-function sym) hook)))
|
||||
|
@ -1006,8 +1006,7 @@ Returns list of symbols and documentation found."
|
||||
"Like `documentation', except it avoids calling `get_doc_string'.
|
||||
Will return nil instead."
|
||||
(while (and function (symbolp function))
|
||||
(setq function (if (fboundp function)
|
||||
(symbol-function function))))
|
||||
(setq function (symbol-function function)))
|
||||
(if (eq (car-safe function) 'macro)
|
||||
(setq function (cdr function)))
|
||||
(setq function (if (byte-code-function-p function)
|
||||
|
@ -248,10 +248,10 @@
|
||||
(defun byte-compile-inline-expand (form)
|
||||
(let* ((name (car form))
|
||||
(localfn (cdr (assq name byte-compile-function-environment)))
|
||||
(fn (or localfn (and (fboundp name) (symbol-function name)))))
|
||||
(fn (or localfn (symbol-function name))))
|
||||
(when (autoloadp fn)
|
||||
(autoload-do-load fn)
|
||||
(setq fn (or (and (fboundp name) (symbol-function name))
|
||||
(setq fn (or (symbol-function name)
|
||||
(cdr (assq name byte-compile-function-environment)))))
|
||||
(pcase fn
|
||||
(`nil
|
||||
|
@ -1265,8 +1265,7 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
|
||||
(if (byte-code-function-p def)
|
||||
(aref def 0)
|
||||
'(&rest def)))))
|
||||
(if (and (fboundp (car form))
|
||||
(subrp (symbol-function (car form))))
|
||||
(if (subrp (symbol-function (car form)))
|
||||
(subr-arity (symbol-function (car form))))))
|
||||
(ncall (length (cdr form))))
|
||||
;; Check many or unevalled from subr-arity.
|
||||
@ -2396,9 +2395,8 @@ not to take responsibility for the actual compilation of the code."
|
||||
(byte-compile-warn "%s `%s' defined multiple times in this file"
|
||||
(if macro "macro" "function")
|
||||
name)))
|
||||
((and (fboundp name)
|
||||
(eq (car-safe (symbol-function name))
|
||||
(if macro 'lambda 'macro)))
|
||||
((eq (car-safe (symbol-function name))
|
||||
(if macro 'lambda 'macro))
|
||||
(when (byte-compile-warning-enabled-p 'redefine)
|
||||
(byte-compile-warn "%s `%s' being redefined as a %s"
|
||||
(if macro "function" "macro")
|
||||
@ -2532,7 +2530,7 @@ If FORM is a lambda or a macro, byte-compile it as a function."
|
||||
(byte-compile-close-variables
|
||||
(let* ((lexical-binding lexical-binding)
|
||||
(fun (if (symbolp form)
|
||||
(and (fboundp form) (symbol-function form))
|
||||
(symbol-function form)
|
||||
form))
|
||||
(macro (eq (car-safe fun) 'macro)))
|
||||
(if macro
|
||||
@ -2946,8 +2944,7 @@ for symbols generated by the byte compiler itself."
|
||||
(format "; use `%s' instead."
|
||||
interactive-only))
|
||||
(t "."))))
|
||||
(if (and (fboundp (car form))
|
||||
(eq (car-safe (symbol-function (car form))) 'macro))
|
||||
(if (eq (car-safe (symbol-function (car form))) 'macro)
|
||||
(byte-compile-log-warning
|
||||
(format "Forgot to expand macro %s" (car form)) nil :error))
|
||||
(if (and handler
|
||||
|
@ -512,8 +512,7 @@ In the absence of INDEX, just call `eldoc-docstring-format-sym-doc'."
|
||||
|
||||
;; Do indirect function resolution if possible.
|
||||
(defun eldoc-symbol-function (fsym)
|
||||
(let ((defn (and (fboundp fsym)
|
||||
(symbol-function fsym))))
|
||||
(let ((defn (symbol-function fsym)))
|
||||
(and (symbolp defn)
|
||||
(condition-case _
|
||||
(setq defn (indirect-function fsym))
|
||||
|
@ -1145,8 +1145,8 @@ Marks the function with their arguments, and returns a list of variables."
|
||||
(defun elint-find-builtins ()
|
||||
"Return a list of all built-in functions."
|
||||
(let (subrs)
|
||||
(mapatoms (lambda (s) (and (fboundp s) (subrp (symbol-function s))
|
||||
(setq subrs (cons s subrs)))))
|
||||
(mapatoms (lambda (s) (and (subrp (symbol-function s))
|
||||
(push s subrs))))
|
||||
subrs))
|
||||
|
||||
(defun elint-find-builtin-args (&optional list)
|
||||
|
@ -1446,10 +1446,10 @@ Otherwise just move the line. Move down unless UP is non-nil."
|
||||
|
||||
;; Newer versions of comint.el changed the name of comint-filter to
|
||||
;; comint-output-filter.
|
||||
(defun idlwave-shell-comint-filter (process string) nil)
|
||||
(if (fboundp 'comint-output-filter)
|
||||
(fset 'idlwave-shell-comint-filter (symbol-function 'comint-output-filter))
|
||||
(fset 'idlwave-shell-comint-filter (symbol-function 'comint-filter)))
|
||||
(defalias 'idlwave-shell-comint-filter
|
||||
(if (fboundp 'comint-output-filter)
|
||||
#'comint-output-filter
|
||||
#'comint-filter))
|
||||
|
||||
(defun idlwave-shell-is-running ()
|
||||
"Return t if the shell process is running."
|
||||
|
@ -1810,7 +1810,7 @@ If TYPE is nil, then any kind of definition is acceptable. If
|
||||
TYPE is `defun', `defvar', or `defface', that specifies function
|
||||
definition, variable definition, or face definition only."
|
||||
(if (and (or (null type) (eq type 'defun))
|
||||
(symbolp symbol) (fboundp symbol)
|
||||
(symbolp symbol)
|
||||
(autoloadp (symbol-function symbol)))
|
||||
(nth 1 (symbol-function symbol))
|
||||
(let ((files load-history)
|
||||
|
Loading…
Reference in New Issue
Block a user