]> git.eshelyaron.com Git - emacs.git/log
emacs.git
9 years ago* lisp/emacs-lisp/cl-generic.el: Add a method-combination hook.
Stefan Monnier [Mon, 26 Jan 2015 14:04:55 +0000 (09:04 -0500)]
* lisp/emacs-lisp/cl-generic.el: Add a method-combination hook.

(cl-generic-method-combination-function): New var.
(cl--generic-lambda): Remove `with-cnm' arg.
(cl-defmethod): Change accordingly.
(cl-generic-define-method): Don't check qualifiers validity.
Preserve all qualifiers in `method-table'.
(cl-generic-call-method): New function.
(cl--generic-nest): Remove (morph into cl-generic-call-method).
(cl--generic-build-combined-method): Adjust to new format of method-table
and use cl-generic-method-combination-function.
(cl--generic-standard-method-combination): New function, extracted from
cl--generic-build-combined-method.
(cl--generic-cnm-sample): Adjust to new format of method-table.

* lisp/emacs-lisp/eieio-compat.el (eieio--defmethod): Use () qualifiers
instead of :primary.

* lisp/emacs-lisp/eieio-datadebug.el (eieio-debug-methodinvoke):
Remove obsolete function.

* test/automated/cl-generic-tests.el (cl-generic-test-11-next-method-p):
New test.

9 years agolisp/gnus/nnimap.el Allow using the Google X-GM-LABELS, if present
Trevor Murphy [Mon, 26 Jan 2015 07:56:37 +0000 (07:56 +0000)]
lisp/gnus/nnimap.el Allow using the Google X-GM-LABELS, if present

9 years ago* lisp/net/shr.el (shr-make-table-1): Fix colspan typo.
Lars Magne Ingebrigtsen [Mon, 26 Jan 2015 05:14:17 +0000 (16:14 +1100)]
* lisp/net/shr.el (shr-make-table-1): Fix colspan typo.

9 years agoUpdate the etc/publicsuffix.txt file
Lars Magne Ingebrigtsen [Mon, 26 Jan 2015 04:21:01 +0000 (15:21 +1100)]
Update the etc/publicsuffix.txt file

* etc/publicsuffix.txt: Install an updated version of the file from
https://publicsuffix.org/list/effective_tld_names.dat.

9 years ago[Gnus] Fixups when displaying certain attachments
Peder O. Klingenberg [Mon, 26 Jan 2015 04:19:51 +0000 (04:19 +0000)]
[Gnus] Fixups when displaying certain attachments

9 years ago[Gnus] Make moving IMAP articles faster in large groups
Lars Ingebrigtsen [Mon, 26 Jan 2015 04:18:57 +0000 (04:18 +0000)]
[Gnus] Make moving IMAP articles faster in large groups

9 years agolisp/calculator.el (calculator-update-display): Bug fix & improvement.
Eli Barzilay [Mon, 26 Jan 2015 03:42:01 +0000 (22:42 -0500)]
lisp/calculator.el (calculator-update-display): Bug fix & improvement.

Avoid a crash when the daved ptr is at the end of the list (= when it's
before the first one).  Also use `eq' to compare the value so the saved
list indicator appears when a value was retrieved from the list rather
than an equal result is shown.

9 years ago* lisp/net/eww.el (eww-add-bookmark): Fix prompt
Lars Ingebrigtsen [Mon, 26 Jan 2015 01:48:44 +0000 (12:48 +1100)]
* lisp/net/eww.el (eww-add-bookmark): Fix prompt

And clean up the code slightly.

9 years agoUse bool for boolean in w32term.c
Eli Zaretskii [Sun, 25 Jan 2015 22:03:14 +0000 (00:03 +0200)]
Use bool for boolean in w32term.c

 src/w32term.c (x_update_window_begin, x_update_window_end)
 (x_update_end, x_after_update_window_line)
 (x_set_glyph_string_gc, x_draw_glyph_string_background)
 (x_draw_glyph_string_foreground)
 (x_draw_composite_glyph_string_foreground)
 (x_draw_glyphless_glyph_string_foreground)
 (x_draw_image_glyph_string, x_draw_glyph_string)
 (x_draw_stretch_glyph_string, note_mouse_movement)
 (w32_mouse_position, x_scroll_bar_report_motion)
 (x_horizontal_scroll_bar_report_motion, w32_read_socket)
 (w32_set_vertical_scroll_bar, w32_set_horizontal_scroll_bar)
 (w32_draw_window_cursor, x_new_font, x_set_offset)
 (x_set_window_size, x_make_frame_invisible, x_iconify_frame): Use
 bool where appropriate.

9 years agoUse bool for boolean in w32fns.c
Eli Zaretskii [Sun, 25 Jan 2015 21:12:35 +0000 (23:12 +0200)]
Use bool for boolean in w32fns.c

 src/w32fns.c (w32_defined_color, x_decode_color)
 (Fxw_color_defined_p, Fxw_color_values, x_set_icon_type)
 (x_set_menu_bar_lines, x_change_tool_bar_height)
 (x_set_internal_border_width, x_explicitly_set_name)
 (x_implicitly_set_name, Fx_create_frame, w32_window)
 (x_create_tip_frame, Fx_show_tip): Use bool where appropriate.

9 years agoUse bool for boolean in xfns.c
Paul Eggert [Sun, 25 Jan 2015 20:32:49 +0000 (12:32 -0800)]
Use bool for boolean in xfns.c

* xfaces.c (x_update_menu_appearance):
* xfns.c (x_real_positions, x_defined_color, x_decode_color)
(xg_set_icon, xg_set_icon_from_xpm_data, x_set_cursor_color)
(x_set_icon_type, x_set_icon_name, x_set_menu_bar_lines)
(x_change_tool_bar_height, x_set_internal_border_width)
(x_encode_text, x_set_name_internal, x_explicitly_set_name)
(x_implicitly_set_name, x_default_scroll_bar_color_parameter)
(hack_wm_protocols, xic_create_fontsetname, xic_free_xfontset)
(x_window, x_icon, Fx_wm_set_size_hint, Fx_create_frame)
(Fxw_color_defined_p, Fxw_color_values, x_create_tip_frame)
(Fx_show_tip, clean_up_file_dialog, Fx_file_dialog)
(clean_up_dialog, syms_of_xfns):
* xterm.h (xg_set_icon, xg_set_icon_from_xpm_data)
(xic_create_fontsetname):
Use bool for boolean.
* xfns.c: Include bitmaps/gray.xbm unconditionally.

9 years agoCount MANY function args more reliably
Paul Eggert [Sun, 25 Jan 2015 16:33:41 +0000 (08:33 -0800)]
Count MANY function args more reliably

* alloc.c (Fgc_status, purecopy, unbind_to, garbage_collect_1):
* buffer.c (Fbuffer_list, Fkill_buffer):
* callint.c (read_file_name, Fcall_interactively):
* charset.c (Fset_charset_priority, syms_of_charset):
* chartab.c (uniprop_encode_value_numeric):
* coding.c (syms_of_coding):
* composite.c (syms_of_composite):
* data.c (wrong_range):
* dbusbind.c (syms_of_dbusbind):
* dired.c (file_attributes):
* editfns.c (Fdecode_time, update_buffer_properties, format2):
* eval.c (run_hook_with_args_2, apply1, call1, call2, call3)
(call4, call5, call6, call7):
* fileio.c (Finsert_file_contents, choose_write_coding_system)
(Fcar_less_than_car, build_annotations, auto_save_error):
* filelock.c (get_boot_time):
* fns.c (internal_equal, nconc2, Fyes_or_no_p, Fwidget_apply):
(maybe_resize_hash_table, secure_hash):
* font.c (font_style_to_value, font_open_by_name, Flist_fonts):
* fontset.c (fontset_add, Fset_fontset_font):
* ftfont.c (ftfont_lookup_cache):
* gtkutil.c (xg_get_font):
* insdel.c (signal_before_change, signal_after_change):
* keymap.c (append_key):
* lread.c (load_warn_old_style_backquotes, Fload, init_lread):
* minibuf.c (Fread_buffer):
* print.c (print_preprocess):
* process.c (Fformat_network_address, Fmake_network_process)
(server_accept_connection):
* sound.c (Fplay_sound_internal):
* term.c (Fsuspend_tty, Fresume_tty):
* window.c (window_list):
* xdisp.c (run_redisplay_end_trigger_hook, add_to_log)
(message_with_string):
* xfaces.c (Fx_list_fonts):
* xfont.c (syms_of_xfont):
* xselect.c (x_handle_selection_request)
(x_handle_selection_clear, x_clear_frame_selections)
(x_clipboard_manager_error_1):
Prefer CALLMANY and CALLN to counting args by hand.
* doc.c (reread_doc_file): Remove unused code.
* fns.c (concat2, concat3): Redo to avoid need for local-var vector.
(cmpfn_user_defined, hashfn_user_defined, Fmaphash):
Prefer call1 and call2 to Ffuncall.
* keyboard.c (safe_run_hook_funcall, safe_run_hooks):
Use struct literal rather than a local var, for simplicity.
* keymap.c (where_is_internal): Use NULL rather than a pointer
to unused args.
* lisp.h (CALLMANY, CALLN): New macros.
* sound.c (Fplay_sound_internal): Coalesce duplicate code.
Fixes: bug#19634
9 years ago* lisp/emacs-lisp/cl-generic.el: Fix next-method-p test
Stefan Monnier [Sun, 25 Jan 2015 16:09:53 +0000 (11:09 -0500)]
* lisp/emacs-lisp/cl-generic.el: Fix next-method-p test

Fixes: debbugs:19672
* lisp/emacs-lisp/cl-generic.el (cl--generic-no-next-method-function): New.
(cl--generic-build-combined-method, cl--generic-nnm-sample): Use it.
(cl--generic-typeof-types): Add support for `sequence'.
(cl-defmethod): Add non-keywords in the qualifiers.

9 years agolisp/gnus/gnus-group.el (gnus-group-suspend): Close all backends
Lars Ingebrigtsen [Sun, 25 Jan 2015 12:18:51 +0000 (12:18 +0000)]
lisp/gnus/gnus-group.el (gnus-group-suspend): Close all backends

9 years ago* indent/shell.sh (bar): Use '[ $# -eq 0 ]', not '[ $# == 0 ]'.
Paul Eggert [Sun, 25 Jan 2015 03:00:41 +0000 (19:00 -0800)]
* indent/shell.sh (bar): Use '[ $# -eq 0 ]', not '[ $# == 0 ]'.

This is more portable in shell scripts.
Fixes: bug#19658
9 years agoUse gnustep-config if available
Paul Eggert [Sun, 25 Jan 2015 02:05:33 +0000 (18:05 -0800)]
Use gnustep-config if available

* configure.ac (--with-gnustep): Document this.
(NS_GNUSTEP_CONFIG): New variable, set if gnustep-config works.
If gnustep-config works, use 'gnustep-config --objc-flags' and
'gnustep-config --gui-libs' to compute GNUstep configuration
variables, instead of attempting to infer them individually.
* etc/NEWS: Document this.
* src/emacs.c [NS_IMPL_GNUSTEP]: Don't include <GNUstepBase/GSConfig.h>.
It doesn't appear to be needed, and the inclusion breaks on
Ubuntu 14.10 when 'configure' uses 'gnustep-config'.
Fixes: bug#19507
9 years ago(find-function-regexp): Don't match `defgroup'
Dmitry Gutov [Sun, 25 Jan 2015 00:20:01 +0000 (02:20 +0200)]
(find-function-regexp): Don't match `defgroup'

* lisp/emacs-lisp/find-func.el (find-function-regexp): Don't match
`defgroup' (regression from the previous change here).

9 years agoFix a couple of AM_V_GEN bugs
Paul Eggert [Sat, 24 Jan 2015 00:08:12 +0000 (16:08 -0800)]
Fix a couple of AM_V_GEN bugs

* admin/unidata/Makefile.in (unifiles):
Use AM_V_at instead of AM_V_GEN, since this doesn't generate a file.
* lib-src/Makefile.in (AM_V_GEN, am__v_GEN_, am__v_GEN_0, am__v_GEN_1)
(AM_V_at, am__v_at_, am__v_at_0, am__v_at_1):
New macros, copied from ../src/Makefile.in.

9 years agolisp/net/{eudc,ldap}: Merge branch streamline-eudc-configuration
Stefan Monnier [Fri, 23 Jan 2015 22:20:19 +0000 (17:20 -0500)]
lisp/net/{eudc,ldap}: Merge branch streamline-eudc-configuration

9 years ago* lisp/emacs-lisp/cl-generic.el (cl-no-primary-method): New fun and error.
Stefan Monnier [Fri, 23 Jan 2015 21:50:56 +0000 (16:50 -0500)]
* lisp/emacs-lisp/cl-generic.el (cl-no-primary-method): New fun and error.
(cl--generic-build-combined-method): Use it.

9 years agoFix package tests when TMPDIR is in HOME
Dmitry Gutov [Fri, 23 Jan 2015 00:50:15 +0000 (02:50 +0200)]
Fix package tests when TMPDIR is in HOME

Fixes: debbugs:19657
* test/automated/package-test.el (with-package-test):
Bind `abbreviated-home-dir' to nil.
(package-test-describe-package, package-test-signed):
Expect abbreviated directory names.

9 years agoRe-add and fix prioritized archives test.
Jorgen Schaefer [Thu, 22 Jan 2015 20:06:47 +0000 (21:06 +0100)]
Re-add and fix prioritized archives test.

* automated/package-test.el (package-test-install-prioritized):
Re-add the test case and add priority to the correct repository
this time around.

9 years agosrc/xdisp.c (init_iterator): Restore a comment lost in transition.
Eli Zaretskii [Thu, 22 Jan 2015 17:57:18 +0000 (19:57 +0200)]
src/xdisp.c (init_iterator): Restore a comment lost in transition.

9 years agoAuto-commit of loaddefs files.
Glenn Morris [Thu, 22 Jan 2015 11:21:14 +0000 (06:21 -0500)]
Auto-commit of loaddefs files.

9 years agoCheck exit statuses in lib-src/Makefile
Paul Eggert [Thu, 22 Jan 2015 08:39:30 +0000 (00:39 -0800)]
Check exit statuses in lib-src/Makefile

* Makefile.in ($(DESTDIR)${archlibdir}, install, uninstall)
(mostlyclean, clean, distclean, extraclean):
Check exit statuses more carefully.  Reindent to fit in 80 chars.
(bootstrap-clean maintainer-clean): Remove unnecessary 'true'.

9 years agoUse bool for boolean in xfont.c, xftfont.c, xgselect.c
Paul Eggert [Thu, 22 Jan 2015 07:40:50 +0000 (23:40 -0800)]
Use bool for boolean in xfont.c, xftfont.c, xgselect.c

* xfont.c (xfont_driver, xfont_chars_supported)
(xfont_text_extents):
* xftfont.c (xftfont_get_colors, xftfont_open)
(xftfont_prepare_face, xftfont_done_face)
(xftfont_cached_font_ok):
* xgselect.c (xg_select):
Use bool for boolean.

9 years agoDon't fail if chown or chgrp for 'update-game-score' is unsuccessful.
Ulrich Müller [Thu, 22 Jan 2015 07:24:42 +0000 (08:24 +0100)]
Don't fail if chown or chgrp for 'update-game-score' is unsuccessful.

* lib-src/Makefile.in ($(DESTDIR)${archlibdir}): Don't fail if the
chown or chgrp command is unsuccessful; the 'update-game-score'
program has a fallback for this at runtime.

9 years agoSpelling fix
Paul Eggert [Thu, 22 Jan 2015 06:06:42 +0000 (22:06 -0800)]
Spelling fix

9 years agoDon't downcase system diagnostics' first letters
Paul Eggert [Thu, 22 Jan 2015 04:21:45 +0000 (20:21 -0800)]
Don't downcase system diagnostics' first letters

* etc/NEWS: Document this.
* lisp/emacs-lisp/bytecomp.el (byte-compile-file):
* lisp/ffap.el (find-file-at-point):
* lisp/files.el (insert-file-1):
* lisp/net/ange-ftp.el (ange-ftp-barf-if-not-directory)
(ange-ftp-copy-file-internal):
* lisp/progmodes/etags.el (visit-tags-table):
* lisp/url/url-dav.el (url-dav-delete-directory, url-dav-delete-file)
(url-dav-directory-files):
Keep diagnostics consistent with system's.
* lisp/erc/erc-dcc.el (erc-dcc-server):
* lisp/ffap.el (ffap-machine-p):
Ignore case while comparing diagnostics.
* src/fileio.c (report_file_errno): Don't downcase, and simplify.
Fixes: bug#19642
9 years agoAvoid generating invalid usage info for pathological function
Stefan Monnier [Thu, 22 Jan 2015 04:16:45 +0000 (23:16 -0500)]
Avoid generating invalid usage info for pathological function

Fixes: debbugs:19645
* lisp/help.el (help-make-usage): Don't turn a "_" arg into an empty-string.
* lisp/emacs-lisp/cl-generic.el (cl--generic-lambda): Don't confuse a string
body with a docstring.

9 years agoBetter isolate code that assumes NIL_IS_ZERO
Paul Eggert [Thu, 22 Jan 2015 04:01:10 +0000 (20:01 -0800)]
Better isolate code that assumes NIL_IS_ZERO

Suggested by Stefan Monnier in:
http://lists.gnu.org/archive/html/emacs-devel/2015-01/msg00588.html
* alloc.c (allocate_pseudovector):
Use memclear, not memsetnil, to remove a 'verify'.
* callint.c (Fcall_interactively):
* dispnew.c (realloc_glyph_pool):
* xdisp.c (init_iterator):
Use memclear, not memset, to remove a 'verify'.
* lisp.h (memclear): Rename from memsetnil, and take a byte
count rather than a word count.  All callers changed.

9 years agoxref: Replace defgeneric and defmethod with cl- counterparts
Dmitry Gutov [Thu, 22 Jan 2015 02:24:31 +0000 (04:24 +0200)]
xref: Replace defgeneric and defmethod with cl- counterparts

* lisp/progmodes/xref.el (xref-location-marker, xref-location-group):
Use `cl-defgeneric' and `cl-defmethod' instead of the EIEIO
counterparts.

* lisp/progmodes/etags.el (xref-location-marker): Same.

9 years agoxref: Input history and minor tweaks
Dmitry Gutov [Thu, 22 Jan 2015 02:09:23 +0000 (04:09 +0200)]
xref: Input history and minor tweaks

* lisp/progmodes/xref.el (xref--current): Rename from `xref--selected'.
(xref--inhibit-mark-current): Rename from
`xref--inhibit-mark-selected'.  Update the usages.
(xref-quit): Reword the docstring.  Kill buffers after quitting
windows instead of before.
(xref--insert-xrefs): Tweak help-echo.
(xref--read-identifier-history, xref--read-pattern-history):
New variables.
(xref--read-identifier, xref-find-apropos): Use them.

9 years agoAllow update-game-score to run sgid instead of suid.
Ulrich Müller [Fri, 16 Jan 2015 08:25:25 +0000 (09:25 +0100)]
Allow update-game-score to run sgid instead of suid.

* configure.ac (gamegroup): New AC_SUBST.
(--with-gameuser): Allow to specify a group instead of a user.
In the default case, check at configure time if a 'games' user
exists.
* lib-src/update-game-score.c: Allow the program to run sgid
instead of suid, in order to match common practice for most games.
(main): Check if we are running sgid.  Pass appropriate file
permission bits to 'write_scores'.
(write_scores): New 'mode' argument, instead of hardcoding 0644.
(get_prefix): Update error message.
* lib-src/Makefile.in (gamegroup): New variable, set by configure.
($(DESTDIR)${archlibdir}): Handle both suid or sgid when
installing the 'update-game-score' program.
* lisp/play/gamegrid.el (gamegrid-add-score-with-update-game-score):
Allow the 'update-game-score' helper program to run suid or sgid.

9 years ago* lisp/emacs-lisp/eieio*.el: Fix up warnings and improve compatibility
Stefan Monnier [Wed, 21 Jan 2015 19:39:06 +0000 (14:39 -0500)]
* lisp/emacs-lisp/eieio*.el: Fix up warnings and improve compatibility

Fixes: debbugs:19645
* lisp/emacs-lisp/cl-generic.el (cl-defgeneric): Add support for `declare'.
(cl--generic-setf-rewrite): Setup the setf expander right away.
(cl-defmethod): Make sure the setf expander is setup before we expand
the body.
(cl-defmethod): Silence byte-compiler warnings.
(cl-generic-define-method): Shuffle code to change return value.
(cl--generic-method-info): New function, extracted from
cl--generic-describe.
(cl--generic-describe): Use it.

* lisp/emacs-lisp/eieio-speedbar.el:
* lisp/emacs-lisp/eieio-datadebug.el:
* lisp/emacs-lisp/eieio-custom.el:
* lisp/emacs-lisp/eieio-base.el: Use cl-defmethod.

* lisp/emacs-lisp/eieio-compat.el (eieio--defmethod): Avoid no-next-method
errors when there's a `before' but no `primary'.
(next-method-p): Return nil rather than signal an error.
(eieio-defgeneric): Remove bogus (fboundp 'method).

* lisp/emacs-lisp/eieio-opt.el: Adapt to cl-generic.
(eieio--specializers-apply-to-class-p): New function.
(eieio-all-generic-functions): Use it.
(eieio-method-documentation): Use it as well as cl--generic-method-info.
Change format of return value.
(eieio-help-class): Adapt accordingly.

* lisp/emacs-lisp/eieio.el: Use cl-defmethod.
(defclass): Generate cl-defmethod calls; use setf methods for :accessor.
(eieio-object-name-string): Declare as obsolete.

* test/automated/cl-generic-tests.el (setf cl--generic-2): Make sure
the setf can be used already in the body of the method.

9 years agoAuto-commit of loaddefs files.
Glenn Morris [Wed, 21 Jan 2015 11:20:15 +0000 (06:20 -0500)]
Auto-commit of loaddefs files.

9 years agoRemap quit-window to xref-quit in xref buffers
Dmitry Gutov [Wed, 21 Jan 2015 07:20:04 +0000 (09:20 +0200)]
Remap quit-window to xref-quit in xref buffers

Fixes: debbugs:19466
* lisp/progmodes/xref.el (xref--xref-buffer-mode-map): Define before
the major mode.  Remap `quit-window' to `xref-quit'.
(xref--xref-buffer-mode): Inherit from special-mode.

9 years agoxref: Keep track of temporary buffers
Dmitry Gutov [Wed, 21 Jan 2015 06:43:39 +0000 (08:43 +0200)]
xref: Keep track of temporary buffers

Fixes: debbugs:19466
xref: Keep track of temporary buffers.
* lisp/progmodes/xref.el (xref--temporary-buffers, xref--selected)
(xref--inhibit-mark-selected): New variables.
(xref--mark-selected): New function.
(xref--show-location): Maybe add the buffer to
`xref--temporary-buffers', add `xref--mark-selected' to
`buffer-list-update-hook' there.
(xref--window): Add docstring.
(xref-quit): Rename from `xref--quit'.  Update both references.
Add KILL argument.  When it's non-nil, kill the temporary buffers
that haven't been selected by the user.
(xref--show-xref-buffer): Change the second argument to alist,
extract the values for `xref--window' and
`xref--temporary-buffers' from it.  Add `xref--mark-selected' to
`buffer-list-update-hook' to each buffer in the list.
(xref--show-xrefs): Move the logic of calling `xref-find-function'
here.  Save the difference between buffer lists before and after
it's called as "temporary buffers", and `pass it to
`xref-show-xrefs-function'.
(xref--find-definitions, xref-find-references)
(xref-find-apropos): Update accordingly.

9 years agoemacs-lisp/package.el (package-dir-info): Fix `while' logic.
Artur Malabarba [Wed, 21 Jan 2015 00:20:22 +0000 (22:20 -0200)]
emacs-lisp/package.el (package-dir-info): Fix `while' logic.

9 years agoUndo port to hypothetical nonzero Qnil case
Paul Eggert [Tue, 20 Jan 2015 21:56:14 +0000 (13:56 -0800)]
Undo port to hypothetical nonzero Qnil case

This mostly undoes the previous change in this area.  See:
http://lists.gnu.org/archive/html/emacs-devel/2015-01/msg00570.html
* alloc.c (allocate_pseudovector):
* callint.c (Fcall_interactively):
* dispnew.c (realloc_glyph_pool):
* fringe.c (init_fringe):
* lisp.h (memsetnil):
* xdisp.c (init_iterator):
Simplify by assuming that Qnil is zero, but verify the assumption.
* lisp.h (NIL_IS_ZERO): Revert back to this symbol, removing
NIL_IS_NONZERO.  All uses changed.

9 years agolisp/emacs-lisp/eieio*.el: Rewrite our generics on top of cl-generic
Stefan Monnier [Tue, 20 Jan 2015 20:40:29 +0000 (15:40 -0500)]
lisp/emacs-lisp/eieio*.el: Rewrite our generics on top of cl-generic

* lisp/emacs-lisp/eieio-generic.el: Remove.
(defgeneric, defmethod): Move to eieio-compat.el.  Mark obsolete.
* lisp/emacs-lisp/eieio-compat.el: New file.
* lisp/emacs-lisp/eieio.el: Don't require eieio-generic any more.
* lisp/emacs-lisp/eieio-core.el (eieio--slot-originating-class-p):
Remove unused function.
(eieio-defclass): Move to eieio-compat.el.
* lisp/emacs-lisp/macroexp.el (macroexp-macroexpand): New function.
(macroexp--expand-all): Use it.
* lisp/emacs-lisp/bytecomp.el (byte-compile-recurse-toplevel): Here too.

9 years agoparagraphs: update sentence-end-base :version after changing the default
Michal Nazarewicz [Tue, 20 Jan 2015 18:30:55 +0000 (19:30 +0100)]
paragraphs: update sentence-end-base :version after changing the default

The default value of the `sentence-end-base' defcustom has been changed
in ‘recognise more Unicode characters as end of sentence’ commit but
:version has not been updated accordingly.  Fix that.

9 years agoRemoved test with spurious failures.
Jorgen Schaefer [Tue, 20 Jan 2015 17:08:38 +0000 (18:08 +0100)]
Removed test with spurious failures.

* automated/package-test.el (package-test-install-prioritized):
Removed test due to unreproducable failures.

9 years agoFix double chars in NS port.
Jan Djärv [Tue, 20 Jan 2015 16:22:14 +0000 (17:22 +0100)]
Fix double chars in NS port.

Fixes: debbugs:19531
* nsterm.m (EV_TRAILER2): Set Vinhibit_quit to Qt.

9 years agoeldoc: modify `eldoc-documentation-function' using `add-function'
Michal Nazarewicz [Fri, 5 Dec 2014 18:34:42 +0000 (19:34 +0100)]
eldoc: modify `eldoc-documentation-function' using `add-function'

* lisp/emacs-lisp/eldoc.el (eldoc-documentation-function): Describe how
major modes should use `add-function' to alter value of the variable.

* lisp/hexl.el (hexl-mode): Set `eldoc-documentation-function' using
`add-function' so the default value is always used.
* lisp/ielm.el (inferior-emacs-lisp-mode): Set
`eldoc-documentation-function' using `add-function' so the default
value is always used.
* lisp/progmodes/cfengine.el (cfengine3-mode): Set
`eldoc-documentation-function' using `add-function' so the default
value is always used.
* lisp/progmodes/elisp-mode (emacs-lisp-mode): Set
`eldoc-documentation-function' using `add-function' so the default
value is always used.
* lisp/progmodes/octave.el (octave-mode): Set
`eldoc-documentation-function' using `add-function' so the default
value is always used.
* lisp/progmodes/python.el (python-mode): Set
`eldoc-documentation-function' using `add-function' so the default
value is always used.
* lisp/simple.el (read--expression): Set `eldoc-documentation-function'
using `add-function' so the default value is always used.

9 years agodescr-text: add `describe-char-eldoc' describing character at point
Michal Nazarewicz [Wed, 3 Dec 2014 18:49:42 +0000 (19:49 +0100)]
descr-text: add `describe-char-eldoc' describing character at point

* lisp/descr-text.el (describe-char-eldoc): New function returning
basic Unicode codepoint information (e.g. name) about character
at point.  It is meant to be used as a default value of the
`eldoc-documentation-function' variable.
(describe-char-eldoc--format, describe-char-eldoc--truncate):
New helper functions for `describe-char-eldoc' function.

* tests/automated/descr-text-test.el: New file with tests for
`describe-char-eldoc--truncate', `describe-char-eldoc--format',
and `describe-char-eldoc'.

9 years agoparagraphs: recognise more Unicode characters as end of sentence
Michal Nazarewicz [Mon, 27 Oct 2014 16:14:38 +0000 (17:14 +0100)]
paragraphs: recognise more Unicode characters as end of sentence

* lisp/textmodes/paragraphs.el (sentence-end-base): Include an
ellipsis (…) and interrobang (‽) characters as end of a sentence,
and a closing single quote (’) as an end of a quote.

9 years agodoh, fixing year in ChangeLog entries introduced by last two commits
Michal Nazarewicz [Tue, 20 Jan 2015 13:03:45 +0000 (14:03 +0100)]
doh, fixing year in ChangeLog entries introduced by last two commits

9 years agotildify: add `tildify-double-space-undos'
Michal Nazarewicz [Sat, 22 Nov 2014 22:28:43 +0000 (23:28 +0100)]
tildify: add `tildify-double-space-undos'

* lisp/textmodes/tildify.el (tildify-double-space-undos): A new
variable specifying whether pressing space in `tildify-mode' after
a space has been replaced with hard space undos the substitution.
(tildify-space): Add code branch for handling `tildify-doule-space'.

* tests/automated/tildify-tests.el (tildify-space-undo-test--test):
A new helper function for testing `tildify-double-space-undos'
behaviour in the `tildify-space' function.
(tildify-space-undo-test-html, tildify-space-undo-test-html-nbsp)
(tildify-space-undo-test-xml, tildify-space-undo-test-tex): New
tests for `tildify-doule-space-undos' behaviour.

9 years agotildify: add `tildify-space' and `tildify-mode'
Michal Nazarewicz [Wed, 15 Oct 2014 08:01:26 +0000 (10:01 +0200)]
tildify: add `tildify-space' and `tildify-mode'

* lisp/textmodes/tildify.el (tildify-space): A new function
which can be used as a `post-self-insert-hook' to automatically
convert spaces into hard spaces.
(tildify-space-pattern): A new variable specifying pattern where
`tildify-space' should take effect.
(tildify-space-predicates): A new variable specifying list of
predicate functions that all must return non-nil for
`tildify-space' to take effect.
(tildify-space-region-predicate): A new functions meant to be
used as a predicate in `tildify-space-predicates' list.
(tildify-mode): A new minor mode enabling `tildify-space' as a
`post-self-insert-hook'

* tests/automated/tildify-tests.el (tildify-space-test--test):
A new helper function for testing `tildify-space' function.
(tildify-space-test-html, tildify-space-test-html-nbsp)
(tildify-space-test-xml, tildify-space-test-tex): New tests for
`tildify-space' function.

9 years agoPrefer xlispstrdup to avoid dumb calls to strlen
Dmitry Antipov [Tue, 20 Jan 2015 10:24:09 +0000 (13:24 +0300)]
Prefer xlispstrdup to avoid dumb calls to strlen

* nsfont.m (ns_get_family):
* nsterm.m (ns_term_init):
* w32fns.c (w32_window):
* xfns.c (x_window, Fx_select_font): Use xlispstrdup.

9 years ago* dispnew.c: Remove no-longer-valid comment.
Paul Eggert [Tue, 20 Jan 2015 08:51:06 +0000 (00:51 -0800)]
* dispnew.c: Remove no-longer-valid comment.

9 years agoMake vc-dir default to repository root
Daniel Colascione [Tue, 20 Jan 2015 05:44:30 +0000 (21:44 -0800)]
Make vc-dir default to repository root

* lisp/vc/vc-dir.el (vc-dir): Default to repository root, not
default-directory.

9 years agoCorrect an old fix for GTK font selection
Paul Eggert [Tue, 20 Jan 2015 04:42:40 +0000 (20:42 -0800)]
Correct an old fix for GTK font selection

* gtkutil.c (xg_get_font): Fix off-by-2 typo.
Fixes: bug#3228
9 years agoFix minor bugs with printing null bytes
Paul Eggert [Tue, 20 Jan 2015 04:28:51 +0000 (20:28 -0800)]
Fix minor bugs with printing null bytes

* minibuf.c (read_minibuf_noninteractive):
* xdisp.c (Ftrace_to_stderr) [GLYPH_DEBUG]:
Work even if the Lisp string contains a null byte.

9 years agoExpand xref help-echo string
Dmitry Gutov [Tue, 20 Jan 2015 02:52:48 +0000 (04:52 +0200)]
Expand xref help-echo string

* lisp/progmodes/xref.el (xref--insert-xrefs): Expand help-echo string.

9 years agoUse etags-goto-tag-location in etags xref backend
Dmitry Gutov [Tue, 20 Jan 2015 02:28:50 +0000 (04:28 +0200)]
Use etags-goto-tag-location in etags xref backend

* progmodes/etags.el (xref-etags-location): New class.
(xref-make-etags-location): New function.
(etags--xref-find-definitions): Use it.
(xref-location-marker): New method implementation.

* lisp/progmodes/xref.el: Mention that xref-location is an EIEIO class.

9 years agoPort to hypothetical case where Qnil is nonzero
Paul Eggert [Tue, 20 Jan 2015 00:49:11 +0000 (16:49 -0800)]
Port to hypothetical case where Qnil is nonzero

* alloc.c (allocate_pseudovector):
* callint.c (Fcall_interactively):
* coding.c (syms_of_coding):
* dispnew.c (realloc_glyph_pool):
* fringe.c (init_fringe):
* lisp.h (memsetnil):
* xdisp.c (init_iterator):
Port to the currently-hypothetical case where Qnil is nonzero.
* dispnew.c (adjust_glyph_matrix): Remove unnecessary verification,
as there are no Lisp_Object values in the data here.
* lisp.h (NIL_IS_NONZERO): New symbol, replacing NIL_IS_ZERO.
All uses changed.  Define only if not already defined, so that one
can debug with -DNIL_IS_NONZERO.
* xdisp.c (init_iterator): Remove unnecessary initializations to 0.

9 years agoVerify that Qnil is zero before relying on that in redisplay.
Eli Zaretskii [Mon, 19 Jan 2015 17:22:17 +0000 (19:22 +0200)]
Verify that Qnil is zero before relying on that in redisplay.

 src/dispnew.c (adjust_glyph_matrix, realloc_glyph_pool): Verify that
 Qnil is represented as zero, before using that to initialize parts
 of the glyph structure.
 src/xdisp.c (init_iterator): Verify that Qnil is represented as
 zero, before using that to initialize parts of the iterator
 structure.

9 years agoFixup ChangeLog
Dmitry Gutov [Mon, 19 Jan 2015 12:00:11 +0000 (14:00 +0200)]
Fixup ChangeLog

9 years ago* lisp/ido.el: Update Customization instructions
Dmitry Gutov [Mon, 19 Jan 2015 11:55:51 +0000 (13:55 +0200)]
* lisp/ido.el: Update Customization instructions

9 years agoSet up ido keymaps only once
Jonas Bernoulli [Mon, 19 Jan 2015 11:54:14 +0000 (13:54 +0200)]
Set up ido keymaps only once

* lisp/ido (ido-common-completion-map)
(ido-file-dir-completion-map)
(ido-file-completion-map, ido-buffer-completion-map): Set up key
bindings when each variable is defined.
(ido-completion-map): Move definition.
(ido-init-completion-maps): Noop.
(ido-common-initialization): Don't call it.
(ido-setup-completion-map): Improve doc-string, cleanup.

Fixes: debbugs:17000
9 years agoFix the value default-directory gets in custom-make-dependencies.
Ivan Shmakov [Mon, 19 Jan 2015 09:50:41 +0000 (09:50 +0000)]
Fix the value default-directory gets in custom-make-dependencies.

* lisp/cus-dep.el (custom-make-dependencies): Ensure that
default-directory is interpreted as a directory (see bug#19140.)

9 years agoPrefer memset to repeatedly assigning Qnil
Paul Eggert [Mon, 19 Jan 2015 08:56:18 +0000 (00:56 -0800)]
Prefer memset to repeatedly assigning Qnil

* alloc.c (allocate_pseudovector): Catch more bogus values.
* alloc.c (allocate_pseudovector):
* callint.c (Fcall_interactively):
* coding.c (syms_of_coding):
* fringe.c (init_fringe):
Verify that Qnil == 0.
* callint.c (Fcall_interactively):
* eval.c (Fapply, Ffuncall):
* fns.c (mapcar1, larger_vector):
* font.c (font_expand_wildcards):
* fringe.c (init_fringe):
Prefer memset to assigning zeros by hand.
* callint.c (Fcall_interactively):
Remove duplicate assignment of Qnil to args[i].
* coding.c (syms_of_coding):
Prefer LISP_INITIALLY_ZERO to assigning zeros by hand.
* fileio.c (Ffile_selinux_context):
Rewrite to avoid need for Lisp_Object array.
* lisp.h (XLI_BUILTIN_LISPSYM): New macro.
(DEFINE_LISP_SYMBOL_END): Use it.
(NIL_IS_ZERO): New constant.
(memsetnil): New function.

9 years agoxref: Use other-window-scroll-buffer and user-error
Dmitry Gutov [Mon, 19 Jan 2015 03:29:37 +0000 (05:29 +0200)]
xref: Use other-window-scroll-buffer and user-error

* lisp/progmodes/xref.el (xref--display-position):
Set `other-window-scroll-buffer'.
(xref-goto-xref): Use `user-error'.

9 years agoUse quit-window to hide buffers temporarily displayed by xref
Dmitry Gutov [Mon, 19 Jan 2015 02:19:32 +0000 (04:19 +0200)]
Use quit-window to hide buffers temporarily displayed by xref

* lisp/progmodes/xref.el (xref--display-history): New variable.
(xref--window-configuration): Remove.
(xref--save-to-history): New function.
(xref--display-position): Use it.  Add new argument.
(xref--restore-window-configuration): Remove.
(xref--show-location, xref-show-location-at-point): Update
accordingly.
(xref--xref-buffer-mode): Don't use `pre-command-hook'.
(xref--quit): New command.
(xref-goto-xref): Use it.
(xref--xref-buffer-mode-map): Bind `q' to it.

9 years agoPerform xref jump even inside indentation or at eol
Dmitry Gutov [Sun, 18 Jan 2015 08:15:41 +0000 (10:15 +0200)]
Perform xref jump even inside indentation or at eol

* lisp/progmodes/xref.el (xref-goto-xref): Perform xref jump even inside
indentation or at eol.

9 years ago* lisp/emacs-lisp/eieio-core.el: Add `subclass' specializer for cl-generic.
Stefan Monnier [Sun, 18 Jan 2015 19:08:13 +0000 (14:08 -0500)]
* lisp/emacs-lisp/eieio-core.el: Add `subclass' specializer for cl-generic.

(eieio--generic-subclass-tagcode, eieio--generic-subclass-tag-types):
New functions.
(cl-generic-tagcode-function, cl-generic-tag-types-function): Use them.

* test/automated/eieio-test-methodinvoke.el (eieio-test-cl-generic-1):
Test `subclass' specializer.

9 years agoEIEIO&cl-generic: Add obsolescence warnings and fix corner case
Stefan Monnier [Sun, 18 Jan 2015 17:24:43 +0000 (12:24 -0500)]
EIEIO&cl-generic: Add obsolescence warnings and fix corner case

* lisp/emacs-lisp/cl-generic.el (cl-generic-define-method): Correctly handle
introduction of a new dispatch argument.
(cl--generic-cache-miss): Handle dispatch on an argument which was not
considered as dispatchable for this method.
(cl-defmethod): Warn when adding a method to an obsolete generic function.
(cl--generic-lambda): Make sure it works if cl-lib is not yet loaded.

* lisp/emacs-lisp/eieio-generic.el (eieio--defgeneric-init-form):
Use autoloadp.

* lisp/emacs-lisp/eieio.el (defclass): Add obsolescence warning for the
`newname' argument.

* test/automated/cl-generic-tests.el (cl-generic-test-10-weird): New test.
Rename other tests to preserve ordering.

9 years ago(package--append-to-alist): Updated docstring due to new name.
Artur Malabarba [Sun, 18 Jan 2015 12:38:19 +0000 (10:38 -0200)]
(package--append-to-alist): Updated docstring due to new name.

9 years agopackage.el (package--append-to-alist): Renamed from `add-to-alist'
Artur Malabarba [Sun, 18 Jan 2015 12:13:07 +0000 (10:13 -0200)]
package.el (package--append-to-alist): Renamed from `add-to-alist'

9 years agoFix seq-subseq and cl-subseq for bad bounding indices
Leo Liu [Sun, 18 Jan 2015 06:03:59 +0000 (14:03 +0800)]
Fix seq-subseq and cl-subseq for bad bounding indices

Fixes: debbugs:19434 debbugs:19519
* lisp/emacs-lisp/cl-extra.el (cl-subseq): Use seq-subseq and fix
multiple evaluation.

* lisp/emacs-lisp/seq.el (seq-subseq): Throw bad bounding indices
error.

* test/automated/seq-tests.el (test-seq-subseq): Add more tests.

9 years ago* lisp/emacs-lisp/cl-generic.el: Add support for cl-next-method-p.
Stefan Monnier [Sun, 18 Jan 2015 03:50:50 +0000 (22:50 -0500)]
* lisp/emacs-lisp/cl-generic.el: Add support for cl-next-method-p.

(cl-defmethod): Add edebug spec.
(cl--generic-build-combined-method): Fix call to
cl-no-applicable-method.
(cl--generic-nnm-sample, cl--generic-cnm-sample): New constant.
(cl--generic-isnot-nnm-p): New function.
(cl--generic-lambda): Use it to add support for cl-next-method-p.
(cl-no-next-method, cl-no-applicable-method): Simplify arg list.
(cl-next-method-p): New function.

9 years agoFix mistake in rebase/merge conflict resolution.
Ulrich Müller [Sat, 17 Jan 2015 23:06:13 +0000 (00:06 +0100)]
Fix mistake in rebase/merge conflict resolution.

Remove lines from lisp/vc/vc-bzr.el again that were accidentally
restored in commit 2015-01-17T09:56:45!ulm@gentoo.org.
(Previously removed in commit 2014-12-01T13:24:27Z!esr@thyrsus.com.)

9 years agoUpdate docstring of emacs-repository-get-version.
Ulrich Müller [Sat, 17 Jan 2015 22:19:15 +0000 (23:19 +0100)]
Update docstring of emacs-repository-get-version.

* version.el (emacs-repository-get-version): Update docstring.

9 years agoUnloading support for misearch.
Ivan Shmakov [Sat, 17 Jan 2015 19:15:51 +0000 (19:15 +0000)]
Unloading support for misearch.

* lisp/misearch.el (multi-isearch-unload-function): New function.
(misearch-unload-function): New alias.

Fixes: debbugs:19566
9 years agoDo not clear the session when trying to read a non-existent desktop file.
Ivan Shmakov [Sat, 17 Jan 2015 19:12:45 +0000 (19:12 +0000)]
Do not clear the session when trying to read a non-existent desktop file.

* lisp/desktop.el (desktop-read): Do not call desktop-clear when no
desktop file is found.

Fixes: debbugs:18371
9 years agoFix: inhibit point motion hooks when encoding an enriched document.
Ivan Shmakov [Sat, 17 Jan 2015 19:07:07 +0000 (19:07 +0000)]
Fix: inhibit point motion hooks when encoding an enriched document.

* lisp/textmodes/enriched.el (enriched-encode): Use
inhibit-point-motion-hooks in addition to inhibit-read-only.

Fixes: debbugs:18246
9 years agoFix dir-locals handling for non-file buffers.
Ivan Shmakov [Sat, 17 Jan 2015 19:02:00 +0000 (19:02 +0000)]
Fix dir-locals handling for non-file buffers.

* lisp/files.el (dir-locals-collect-variables): Use default-directory
in place of the file name while working on non-file buffers, just
like hack-dir-local-variables already does.

Fixes: debbugs:19140
9 years agoAvoid mapcar in two cases in files.el.
Ivan Shmakov [Sat, 17 Jan 2015 18:57:04 +0000 (18:57 +0000)]
Avoid mapcar in two cases in files.el.

* lisp/files.el (find-file-other-window, find-file-other-frame):
Use mapc instead of mapcar.

Fixes: debbugs:18175
9 years agoIgnore print-length and print-level while formatting url-cookie data.
Ivan Shmakov [Sat, 17 Jan 2015 18:42:31 +0000 (18:42 +0000)]
Ignore print-length and print-level while formatting url-cookie data.

* lisp/url/url-cookie.el (url-cookie-write-file): Let-bind print-length
and print-level to nil to avoid writing a garbled list.

Fixes: debbugs:16805
9 years ago* lisp/emacs-lisp/eieio-core.el (eieio--class-constructor): Rename.
Stefan Monnier [Sat, 17 Jan 2015 14:50:07 +0000 (09:50 -0500)]
* lisp/emacs-lisp/eieio-core.el (eieio--class-constructor): Rename.

Fixes: debbugs:19620
(eieio--class-constructor): Rename from class-constructor, and make it an alias
for `identity'.  Update all callers.

9 years ago* lisp/emacs-lisp/eieio.el: Improve `constructor' compatibility.
Stefan Monnier [Sat, 17 Jan 2015 14:41:51 +0000 (09:41 -0500)]
* lisp/emacs-lisp/eieio.el: Improve `constructor' compatibility.

Fixes: debbugs:19620
(eieio-constructor): Handle obsolete object name argument here...
(defclass): ...instead of in the constructor here.

* test/automated/eieio-tests.el
(eieio-test-37-obsolete-name-in-constructor): New test.

9 years agoType fix for defcustom.
Jorgen Schaefer [Sat, 17 Jan 2015 10:58:58 +0000 (11:58 +0100)]
Type fix for defcustom.

* emacs-lisp/package.el (package-archive-priorities): Specify
correct type.

9 years agoDiscard the Bazaar case in repository version detection
Ulrich Müller [Fri, 14 Nov 2014 08:05:02 +0000 (09:05 +0100)]
Discard the Bazaar case in repository version detection

* version.el (emacs-bzr-version-dirstate, emacs-bzr-version-bzr):
Remove.
(emacs-repository-get-version): Discard the Bazaar case.

* vc/vc-bzr.el (vc-bzr-version-dirstate): Rename from
emacs-bzr-version-dirstate and move from version.el to here.
(vc-bzr-working-revision): Use it.

9 years agoDon't enforce :protection in EIEIO objects any more
Stefan Monnier [Sat, 17 Jan 2015 04:48:26 +0000 (23:48 -0500)]
Don't enforce :protection in EIEIO objects any more

* doc/misc/eieio.texi (Slot Options): Document :protection as unsupported.

* lisp/emacs-lisp/eieio-core.el (eieio--scoped-class-stack): Remove var.
(eieio--scoped-class): Remove function.
(eieio--with-scoped-class): Remove macro.  Replace uses with `progn'.
(eieio--slot-name-index): Don't check the :protection anymore.
(eieio-initializing-object): Remove var.
(eieio-set-defaults): Don't let-bind eieio-initializing-object.

* lisp/emacs-lisp/eieio-generic.el (call-next-method): Don't bother checking
eieio--scoped-class any more.

* test/automated/eieio-test-methodinvoke.el (eieio-test-method-store):
Use an explicit arg instead of eieio--scoped-class.  Update all callers.

* test/automated/eieio-tests.el (eieio-test-25-slot-tests)
(eieio-test-26-default-inheritance, eieio-test-28-slot-protection)
(eieio-test-30-slot-attribute-override)
(eieio-test-31-slot-attribute-override-class-allocation): Don't check
that we enforce :protection since we don't any more.

9 years agoImprove handling of doc-strings and describe-function for cl-generic
Stefan Monnier [Sat, 17 Jan 2015 03:52:15 +0000 (22:52 -0500)]
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.

9 years agoemacs-lisp/package.el and package-x.el: References to package-desc-kind
Artur Malabarba [Wed, 14 Jan 2015 14:57:32 +0000 (12:57 -0200)]
emacs-lisp/package.el and package-x.el: References to package-desc-kind

9 years ago* NEWS: Document installing packages from directories.
Artur Malabarba [Tue, 13 Jan 2015 02:13:55 +0000 (00:13 -0200)]
* NEWS: Document installing packages from directories.

9 years ago(package-install-file): Install packages from directory.
Artur Malabarba [Tue, 13 Jan 2015 02:03:59 +0000 (00:03 -0200)]
(package-install-file): Install packages from directory.

9 years ago(package-install-from-buffer): Install packages from dired buffer.
Artur Malabarba [Tue, 13 Jan 2015 01:35:46 +0000 (23:35 -0200)]
(package-install-from-buffer): Install packages from dired buffer.

9 years ago* emacs-lisp/package.el (package-dir-info): New function.
Artur Malabarba [Tue, 13 Jan 2015 01:26:58 +0000 (23:26 -0200)]
* emacs-lisp/package.el (package-dir-info): New function.

Find package information for a directory. The return result is a
`package-desc'.

9 years ago* emacs-lisp/package.el (package--read-pkg-desc): New function.
Artur Malabarba [Tue, 13 Jan 2015 01:24:22 +0000 (23:24 -0200)]
* emacs-lisp/package.el (package--read-pkg-desc): New function.

Read a `define-package' form in current buffer. Return the pkg-desc,
with desc-kind set to KIND.

9 years ago* lisp/emacs-lisp/cl-macs.el: Fix last change.
Stefan Monnier [Thu, 15 Jan 2015 13:58:45 +0000 (08:58 -0500)]
* lisp/emacs-lisp/cl-macs.el: Fix last change.

(cl--labels-magic): New constant.
(cl--labels-convert): Use it to ask the macro what is its replacement
in the #'f case.

9 years ago* lisp/emacs-lisp/cl-generic.el (cl--generic-build-combined-method):
Stefan Monnier [Thu, 15 Jan 2015 13:38:00 +0000 (08:38 -0500)]
* lisp/emacs-lisp/cl-generic.el (cl--generic-build-combined-method):
Return the value of the primary rather than the after method.

9 years agoFix the automated test for package priorities.
Jorgen Schaefer [Fri, 16 Jan 2015 19:28:26 +0000 (20:28 +0100)]
Fix the automated test for package priorities.

* automated/package-test.el (package-test-install-prioritized):
New test.

9 years ago# ChangeLog fixes
Glenn Morris [Fri, 16 Jan 2015 19:17:25 +0000 (14:17 -0500)]
# ChangeLog fixes

9 years agoPrefer INLINE functions in font.h to match style used in lisp.h
Dmitry Antipov [Fri, 16 Jan 2015 12:15:32 +0000 (15:15 +0300)]
Prefer INLINE functions in font.h to match style used in lisp.h

* font.h (FONTP, FONT_SPEC_P, FONT_ENTITY_P, FONT_OBJECT_P)
(CHECK_FONT, CHECK_FONT_SPEC, CHECK_FONT_ENTITY, CHECK_FONT_OBJECT)
(XFONT_SPEC, XFONT_ENTITY, XFONT_OBJECT, CHECK_FONT_GET_OBJECT):
Now functions.
* font.c (Ffont_otf_alternates, Fquery_font, Ffont_get_glyphs):
* ftfont.c (ftfont_shape):
* macfont.m (macfont_shape):
* w32uniscribe.c (uniscribe_shape):
* xftfont.c (xftfont_shape): Adjust CHECK_FONT_GET_OBJECT users.

9 years agoTiny lisp.h cleanup
Dmitry Antipov [Fri, 16 Jan 2015 11:41:20 +0000 (14:41 +0300)]
Tiny lisp.h cleanup

* lisp.h (XTERMINAL): Add eassert.
* process.c (make_lisp_proc): Now static here.

9 years agoPackage archives now have priorities.
Jorgen Schaefer [Sun, 7 Dec 2014 21:28:38 +0000 (22:28 +0100)]
Package archives now have priorities.

* lisp/package.el: Provide repository priorities.
(package-archive-priorities): New variable.
(package--add-to-alist): New function.
(package--add-to-archive-contents): Use it.
(package-menu--find-upgrades): Use it as well. Small clean up to
make the use of the package name here explicit.
(package-archive-priority): New function.
(package-desc-priority-version): New function.

Fixes: debbugs:19296