emacs/lisp/emacs-lisp
Stefan Monnier 24b7f77581 Improve handling of doc-strings and describe-function for cl-generic
* lisp/help-fns.el (find-lisp-object-file-name): Accept any `type' as long
as it's a symbol.
(help-fns-short-filename): New function.
(describe-function-1): Use it.  Use autoload-do-load.

* lisp/help-mode.el (help-function-def): Add optional arg `type'.

* lisp/emacs-lisp/cl-generic.el (cl-generic-ensure-function): It's OK to
override an autoload.
(cl-generic-current-method-specializers): Replace dyn-bind variable
with a lexically-scoped macro.
(cl--generic-lambda): Update accordingly.
(cl-generic-define-method): Record manually in the load-history with
type `cl-defmethod'.
(cl--generic-get-dispatcher): Minor optimization.
(cl--generic-search-method): New function.
(find-function-regexp-alist): Add entry for `cl-defmethod' type.
(cl--generic-search-method): Add hyperlinks for methods.  Merge the
specializers and the function's arguments.

* lisp/emacs-lisp/eieio-core.el (eieio--defalias): Move to eieio-generic.el.
(eieio-defclass-autoload): Don't record the superclasses any more.
(eieio-defclass-internal): Reuse the old class object if it was just an
autoload stub.
(eieio--class-precedence-list): Load the class if it's autoloaded.

* lisp/emacs-lisp/eieio-generic.el (eieio--defalias): Move from eieio-core.
(eieio--defgeneric-init-form): Don't throw away a previous docstring.
(eieio--method-optimize-primary): Don't mess with the docstring.
(defgeneric): Keep the `args' in the docstring.
(defmethod): Don't use the method's docstring for the generic
function's docstring.

* lisp/emacs-lisp/find-func.el: Use lexical-binding.
(find-function-regexp): Don't rule out `defgeneric'.
(find-function-regexp-alist): Document new possibility of including
a function instead of a regexp.
(find-function-search-for-symbol): Implement that new possibility.
(find-function-library): Don't assume that `function' is a symbol.
(find-function-do-it): Remove unused var `orig-buf'.

* test/automated/cl-generic-tests.el (cl-generic-test-8-after/before):
Rename from cl-generic-test-7-after/before.
(cl--generic-test-advice): New function.
(cl-generic-test-9-advice): New test.

* test/automated/eieio-test-methodinvoke.el (eieio-test-cl-generic-1): Reset
eieio-test--1.
2015-01-16 22:52:15 -05:00
..
advice.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
autoload.el Less 'make' chatter in batch mode 2015-01-03 18:29:23 -08:00
avl-tree.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
backquote.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
benchmark.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
bindat.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
byte-opt.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
byte-run.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
bytecomp.el Less 'make' chatter in batch mode 2015-01-03 18:29:23 -08:00
cconv.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
chart.el Shrink EIEIO object header. Move generics to eieio-generic.el. 2015-01-08 16:03:04 -05:00
check-declare.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
checkdoc.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
cl-extra.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
cl-generic.el Improve handling of doc-strings and describe-function for cl-generic 2015-01-16 22:52:15 -05:00
cl-indent.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
cl-lib.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
cl-macs.el * lisp/emacs-lisp/cl-macs.el: Fix last change. 2015-01-16 17:49:00 -05:00
cl-seq.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
cl.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
copyright.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
crm.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
debug.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
derived.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
disass.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
easy-mmode.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
easymenu.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
edebug.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
eieio-base.el * emacs-lisp/eieio-generic.el: New file. 2015-01-08 00:24:24 -05:00
eieio-core.el Improve handling of doc-strings and describe-function for cl-generic 2015-01-16 22:52:15 -05:00
eieio-custom.el Shrink EIEIO object header. Move generics to eieio-generic.el. 2015-01-08 16:03:04 -05:00
eieio-datadebug.el * emacs-lisp/eieio-generic.el: New file. 2015-01-08 00:24:24 -05:00
eieio-generic.el Improve handling of doc-strings and describe-function for cl-generic 2015-01-16 22:52:15 -05:00
eieio-opt.el * lisp/emacs-lisp/eieio*.el: Move the function defs to defclass. 2015-01-08 15:47:32 -05:00
eieio-speedbar.el Shrink EIEIO object header. Move generics to eieio-generic.el. 2015-01-08 16:03:04 -05:00
eieio.el Shrink EIEIO object header. Move generics to eieio-generic.el. 2015-01-08 16:03:04 -05:00
eldoc.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
elint.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
elp.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
ert-x.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
ert.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
ewoc.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
find-func.el Improve handling of doc-strings and describe-function for cl-generic 2015-01-16 22:52:15 -05:00
float-sup.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
generic.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
gv.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
helper.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
inline.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
lisp-mnt.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
lisp-mode.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
lisp.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
macroexp.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
map-ynp.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
nadvice.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
package-x.el emacs-lisp/package.el and package-x.el: References to package-desc-kind 2015-01-16 22:21:12 -02:00
package.el emacs-lisp/package.el and package-x.el: References to package-desc-kind 2015-01-16 22:21:12 -02:00
pcase.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
pp.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
re-builder.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
regexp-opt.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
regi.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
ring.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
rx.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
seq.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
shadow.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
smie.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
subr-x.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
syntax.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
tabulated-list.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
tcover-ses.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
tcover-unsafep.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
testcover.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
timer.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
tq.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
trace.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
unsafep.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00
warnings.el Update copyright year to 2015 2015-01-01 14:26:41 -08:00