bpt/emacs.git
13 years agoUpdate from gnulib.
Paul Eggert [Tue, 26 Apr 2011 19:29:47 +0000 (12:29 -0700)]
Update from gnulib.

13 years ago* lisp.h: Add comments about struct vectorlike_header.
Paul Eggert [Tue, 26 Apr 2011 19:14:07 +0000 (12:14 -0700)]
* lisp.h: Add comments about struct vectorlike_header.

13 years ago* keyboard.c (handle_user_signal): Fix pointer signedness problem.
Paul Eggert [Tue, 26 Apr 2011 18:02:10 +0000 (11:02 -0700)]
* keyboard.c (handle_user_signal): Fix pointer signedness problem.

13 years agoMerge from mainline.
Paul Eggert [Tue, 26 Apr 2011 17:50:51 +0000 (10:50 -0700)]
Merge from mainline.

13 years agoFix typos in ChangeLogs.
Juanma Barranquero [Tue, 26 Apr 2011 14:07:29 +0000 (16:07 +0200)]
Fix typos in ChangeLogs.

13 years agosrc/keyboard.c (QCrtl): Rename from Qrtl. All uses changed.
Juanma Barranquero [Tue, 26 Apr 2011 14:02:55 +0000 (16:02 +0200)]
src/keyboard.c (QCrtl): Rename from Qrtl.  All uses changed.

13 years agoMake ERC use completion-at-point
Stefan Monnier [Tue, 26 Apr 2011 13:50:09 +0000 (10:50 -0300)]
Make ERC use completion-at-point
* lisp/erc/erc.el (erc-mode-map): Use completion-at-point.
(erc-mode): Tell completion-at-point to obey erc-complete-functions.
(erc-complete-word-at-point): New function.
(erc-complete-word): Make it obsolete.
* lisp/erc/erc-pcomplete.el (erc-pcompletions-at-point): New function.
(pcomplete): Use it.
* lisp/erc/erc-dcc.el (erc-dcc-chat-mode-map): Use completion-at-point.
(erc-dcc-chat-mode): Tell completion-at-point to obey
erc-complete-functions.
* lisp/erc/erc-button.el (erc-button-next-function): New function extracted from
erc-button-next.
(button, erc-button-next): Use it.

13 years agoDon't return in emacs_gnutls_handshake without an explicit value.
Ted Zlatanov [Tue, 26 Apr 2011 12:59:12 +0000 (07:59 -0500)]
Don't return in emacs_gnutls_handshake without an explicit value.

* gnutls.c (emacs_gnutls_handshake): Return an error if we're not
supposed to be handshaking.
Reported by Paul Eggert <eggert@cs.ucla.edu>.

13 years agoFix verb tense in ChangeLog message.
Ted Zlatanov [Tue, 26 Apr 2011 12:49:53 +0000 (07:49 -0500)]
Fix verb tense in ChangeLog message.

13 years agoImplement debug-on-event
Daniel Colascione [Tue, 26 Apr 2011 11:26:05 +0000 (04:26 -0700)]
Implement debug-on-event

13 years agoImprove Windows quoting robustness
Daniel Colascione [Tue, 26 Apr 2011 10:44:03 +0000 (03:44 -0700)]
Improve Windows quoting robustness

13 years agoAdd bug numbers.
Paul Eggert [Tue, 26 Apr 2011 07:52:52 +0000 (00:52 -0700)]
Add bug numbers.

13 years ago* gnutls.c (emacs_gnutls_write): Don't use uninitialized rtnval if nbyte <= 0.
Paul Eggert [Tue, 26 Apr 2011 07:35:23 +0000 (00:35 -0700)]
* gnutls.c (emacs_gnutls_write): Don't use uninitialized rtnval if nbyte <= 0.

13 years ago* gnutls.c: Remove unused local.
Paul Eggert [Tue, 26 Apr 2011 07:26:02 +0000 (00:26 -0700)]
* gnutls.c: Remove unused local.

13 years ago* gnutls.c (Fgnutls_boot): gnutls_certificate_verify_peers2 wants unsigned *.
Paul Eggert [Tue, 26 Apr 2011 07:23:56 +0000 (00:23 -0700)]
* gnutls.c (Fgnutls_boot): gnutls_certificate_verify_peers2 wants unsigned *.

13 years ago* gnutls.c (emacs_gnutls_handle_error): Remove unused local.
Paul Eggert [Tue, 26 Apr 2011 07:20:51 +0000 (00:20 -0700)]
* gnutls.c (emacs_gnutls_handle_error): Remove unused local.

13 years ago* gnutls.c (emacs_gnutls_handshake): Don't return a garbage value.
Paul Eggert [Tue, 26 Apr 2011 07:12:16 +0000 (00:12 -0700)]
* gnutls.c (emacs_gnutls_handshake): Don't return a garbage value.

Expect the caller to check whether GNUTLS_STAGE_HANDSHAKE_CANDO <=
proc->gnutls_initstage, if the check is needed.  The check isn't
needed for one caller, Fgnutls_boot.
(emacs_gnutls_read): Do that check.  This is the other caller.

13 years agoMerge from mainline.
Paul Eggert [Tue, 26 Apr 2011 06:17:52 +0000 (23:17 -0700)]
Merge from mainline.

13 years ago* admin/notes/bzr: Small updates.
Glenn Morris [Tue, 26 Apr 2011 04:50:33 +0000 (21:50 -0700)]
* admin/notes/bzr: Small updates.

13 years ago* admin/notes/years: Small updates.
Glenn Morris [Tue, 26 Apr 2011 04:45:37 +0000 (21:45 -0700)]
* admin/notes/years: Small updates.

13 years agoCombine changelog entries.
Paul Eggert [Mon, 25 Apr 2011 21:50:24 +0000 (14:50 -0700)]
Combine changelog entries.

13 years ago* lisp.h (XVECTORLIKE_HEADER_SIZE): Remove. The only use is now expanded.
Paul Eggert [Mon, 25 Apr 2011 21:38:32 +0000 (14:38 -0700)]
* lisp.h (XVECTORLIKE_HEADER_SIZE): Remove.  The only use is now expanded.

13 years agoConvert some function definitions to standard C.
Dan Nicolaescu [Mon, 25 Apr 2011 21:36:06 +0000 (14:36 -0700)]
Convert some function definitions to standard C.

* src/alloc.c (check_sblock, check_string_bytes)
(check_string_free_list): Convert to standard C.

13 years ago* lisp.h: (XVECTOR_SIZE): Remove. All uses replaced with ASIZE.
Paul Eggert [Mon, 25 Apr 2011 21:34:39 +0000 (14:34 -0700)]
* lisp.h: (XVECTOR_SIZE): Remove.  All uses replaced with ASIZE.
(ASIZE): Now contains previous implementation of XVECTOR_SIZE
instead of invoking XVECTOR_SIZE.

13 years ago* lisp.h: Say "vectorlike header" rather than "vector header.
Paul Eggert [Mon, 25 Apr 2011 19:40:22 +0000 (12:40 -0700)]
* lisp.h: Say "vectorlike header" rather than "vector header.

(struct vectorlike_header): Rename from struct vector_header.
(XVECTORLIKE_HEADER_SIZE): Renamed from XVECTOR_HEADER_SIZE.
All uses changed.

13 years ago* lisp/emulation/cua-base.el (cua-selection-mode): Make it toggle again.
Stefan Monnier [Mon, 25 Apr 2011 18:17:17 +0000 (15:17 -0300)]
* lisp/emulation/cua-base.el (cua-selection-mode): Make it toggle again.

13 years ago* trampver.texi: Update release number.
Michael Albinus [Mon, 25 Apr 2011 18:14:38 +0000 (20:14 +0200)]
* trampver.texi: Update release number.

13 years ago* net/tramp.el (tramp-process-actions): Add POS argument. Delete
Michael Albinus [Mon, 25 Apr 2011 18:10:17 +0000 (20:10 +0200)]
* net/tramp.el (tramp-process-actions): Add POS argument.  Delete
region between POS and (pos).

* net/tramp-sh.el (tramp-do-copy-or-rename-file-out-of-band): Use
`nil' position in `tramp-process-actions' call.
(tramp-maybe-open-connection): Call `tramp-process-actions' with pos.

* net/tramp-smb.el (tramp-smb-maybe-open-connection): Use `nil'
position in `tramp-process-actions' call.

* net/trampver.el: Update release number.

13 years ago* lisp/custom.el (defcustom): Obey lexical-binding.
Stefan Monnier [Mon, 25 Apr 2011 16:52:51 +0000 (13:52 -0300)]
* lisp/custom.el (defcustom): Obey lexical-binding.

13 years agoFix octave-inf completion problems reported by Alexander Klimov.
Stefan Monnier [Mon, 25 Apr 2011 16:29:31 +0000 (13:29 -0300)]
Fix octave-inf completion problems reported by Alexander Klimov.
* lisp/progmodes/octave-inf.el (inferior-octave-mode-syntax-table):
Inherit from octave-mode-syntax-table.
(inferior-octave-mode): Set info-lookup-mode.
(inferior-octave-completion-at-point): New function.
(inferior-octave-complete): Use it and completion-in-region.
(inferior-octave-dynamic-complete-functions): Use it as well, and use
comint-filename-completion.
* lisp/progmodes/octave-mod.el (octave-mode-syntax-table): Use _ syntax for
symbol elements which shouldn't be word elements.
(octave-font-lock-keywords, octave-beginning-of-defun)
(octave-function-header-regexp): Adjust regexps accordingly.
(octave-mode-map): Also use info-lookup-symbol for C-c C-h.

13 years agolisp/net/gnutls.el (gnutls-errorp): Declare before first use.
Juanma Barranquero [Mon, 25 Apr 2011 13:47:23 +0000 (15:47 +0200)]
lisp/net/gnutls.el (gnutls-errorp): Declare before first use.

13 years agoFix typo in GnuTLS W32 support.
Ted Zlatanov [Mon, 25 Apr 2011 12:48:24 +0000 (07:48 -0500)]
Fix typo in GnuTLS W32 support.

* w32.c (emacs_gnutls_push): Fix typo.

13 years agoAvoid compilation warnings in gnutls.c on 64-bit hosts.
Eli Zaretskii [Mon, 25 Apr 2011 10:42:57 +0000 (13:42 +0300)]
Avoid compilation warnings in gnutls.c on 64-bit hosts.

 src/gnutls.c (emacs_gnutls_handshake): Avoid compiler warnings about
 "cast to pointer from integer of different size".

13 years agoAuto-commit of generated files.
Glenn Morris [Mon, 25 Apr 2011 10:18:22 +0000 (06:18 -0400)]
Auto-commit of generated files.

13 years agoImprove doprnt and its use in verror. (Bug#8545)
Eli Zaretskii [Mon, 25 Apr 2011 08:04:22 +0000 (11:04 +0300)]
Improve doprnt and its use in verror.  (Bug#8545)

 src/doprnt.c (doprnt): Document the set of format control sequences
 supported by the function.  Use SAFE_ALLOCA instead of always
 using `alloca'.
 src/eval.c (verror): Don't limit the buffer size at size_max-1, that
 is one byte too soon.  Don't use xrealloc; instead xfree and
 xmalloc anew.

13 years agoFix minor typos in previous change.
Paul Eggert [Mon, 25 Apr 2011 07:33:57 +0000 (00:33 -0700)]
Fix minor typos in previous change.

13 years agolisp.h: Fix a problem with aliasing and vector headers.
Paul Eggert [Mon, 25 Apr 2011 07:14:46 +0000 (00:14 -0700)]
lisp.h: Fix a problem with aliasing and vector headers.

GCC 4.6.0 optimizes based on type-based alias analysis.  For
example, if b is of type struct buffer * and v of type struct
Lisp_Vector *, then gcc -O2 was incorrectly assuming that &b->size
!= &v->size, and therefore "v->size = 1; b->size = 2; return
v->size;" must therefore return 1.  This assumption is incorrect
for Emacs, since it type-puns struct Lisp_Vector * with many other
types.  To fix this problem, this patch adds a new type struct
vector_header that documents the constraints on layout of vectors
and pseudovectors, and helps optimizing compilers not get fooled
by Emacs's type punning.  It also adds the macros XSETTYPED_PVECTYPE
XSETTYPED_PSEUDOVECTOR, TYPED_PSEUDOVECTORP, for similar reasons.
* lisp.h (XVECTOR_SIZE): New convenience macro.  All previous uses of
XVECTOR (foo)->size replaced to use this macro, to avoid the hassle
of writing XVECTOR (foo)->header.size.
(XVECTOR_HEADER_SIZE): New macro, for use in XSETPSEUDOVECTOR.
(XSETTYPED_PVECTYPE): New macro, specifying the name of the size
member.
(XSETPVECTYPE): Rewrite in terms of new macro.
(XSETPVECTYPESIZE): New macro, specifying both type and size.
This is a bit clearer, and further avoids the possibility of
undesirable aliasing.
(XSETTYPED_PSEUDOVECTOR): New macro, specifying the size.
(XSETPSEUDOVECTOR): Rewrite in terms of XSETTYPED_PSEUDOVECTOR
and XVECTOR_HEADER_SIZE.
(XSETSUBR): Rewrite in terms of XSETTYPED_PSEUDOVECTOR and XSIZE,
since Lisp_Subr is a special case (no "next" field).
(ASIZE): Rewrite in terms of XVECTOR_SIZE.
(struct vector_header): New type.
(TYPED_PSEUDOVECTORP): New macro, also specifying the C type of the
object, to help avoid aliasing.
(PSEUDOVECTORP): Rewrite in terms of TYPED_PSEUDOVECTORP.
(SUBRP): Likewise, since Lisp_Subr is a special case.
* lisp.h (struct Lisp_Vector, struct Lisp_Char_Table):
(struct Lisp_Sub_Char_Table, struct Lisp_Bool_Vector):
(struct Lisp_Hash_Table): Combine first two members into a single
struct vector_header member.  All uses of "size" and "next" members
changed to be "header.size" and "header.next".
* buffer.h (struct buffer): Likewise.
* font.h (struct font_spec, struct font_entity, struct font): Likewise.
* frame.h (struct frame): Likewise.
* process.h (struct Lisp_Process): Likewise.
* termhooks.h (struct terminal): Likewise.
* window.c (struct save_window_data, struct saved_window): Likewise.
* window.h (struct window): Likewise.
* alloc.c (allocate_buffer, Fmake_bool_vector, allocate_pseudovector):
Use XSETPVECTYPESIZE, not XSETPVECTYPE, to avoid aliasing problems.
* buffer.c (init_buffer_once): Likewise.
* lread.c (defsubr): Use XSETTYPED_PVECTYPE, since Lisp_Subr is a
special case.
* process.c (Fformat_network_address): Use local var for size,
for brevity.

13 years agognus-registry.el (gnus-registry-ignore-group-p): Don't call `gnus-parameter-registry...
Teodor Zlatanov [Mon, 25 Apr 2011 04:32:07 +0000 (04:32 +0000)]
gnus-registry.el (gnus-registry-ignore-group-p): Don't call `gnus-parameter-registry-ignore' if the *Group* buffer doesn't exist.

13 years agoBug fixes and certificate and hostname verification for the Emacs GnuTLS support.
Ted Zlatanov [Mon, 25 Apr 2011 01:31:45 +0000 (20:31 -0500)]
Bug fixes and certificate and hostname verification for the Emacs GnuTLS support.

* lisp/net/gnutls.el (gnutls-negotiate): Add hostname, verify-flags,
verify-error, and verify-hostname-error parameters.  Check whether
default trustfile exists before going to use it. Add missing
argument to gnutls-message-maybe call. Return return value.
Reported by Claudio Bley <claudio.bley@gmail.com>.
(open-gnutls-stream): Add usage example.

* lisp/net/network-stream.el (network-stream-open-starttls): Give host
parameter to `gnutls-negotiate'.
(gnutls-negotiate): Adjust `gnutls-negotiate' declaration.

13 years agoAdd GnuTLS support for W32 and certificate and hostname verification in GnuTLS.
Ted Zlatanov [Mon, 25 Apr 2011 01:30:51 +0000 (20:30 -0500)]
Add GnuTLS support for W32 and certificate and hostname verification in GnuTLS.

* src/gnutls.c: Renamed global_initialized to
gnutls_global_initialized.  Added internals for the
:verify-hostname-error, :verify-error, and :verify-flags
parameters of `gnutls-boot' and documented those parameters in the
docstring.  Start callback support.
(emacs_gnutls_handshake): Add Woe32 support. Retry handshake
unless a fatal error occured. Call gnutls_alert_send_appropriate
on error. Return error code.
(emacs_gnutls_write): Call emacs_gnutls_handle_error.
(emacs_gnutls_read): Likewise.
(Fgnutls_boot): Return handshake error code.
(emacs_gnutls_handle_error): New function.
(wsaerror_to_errno): Likewise.

* src/gnutls.h: Add GNUTLS_STAGE_CALLBACKS enum to denote we're in the
callbacks stage.

* src/w32.c (emacs_gnutls_pull): New function for GnuTLS on Woe32.
(emacs_gnutls_push): Likewise.

* src/w32.h (emacs_gnutls_pull): Add prototype.
(emacs_gnutls_push): Likewise.

13 years agoAdd certificate verify callback check for GnuTLS.
Ted Zlatanov [Mon, 25 Apr 2011 01:30:05 +0000 (20:30 -0500)]
Add certificate verify callback check for GnuTLS.

* configure.in: Check for GnuTLS certificate verify callbacks.

13 years agoAdd GnuTLS support for W32.
Ted Zlatanov [Mon, 25 Apr 2011 01:29:31 +0000 (20:29 -0500)]
Add GnuTLS support for W32.

* nt/configure.bat: New options --without-gnutls and --lib, new build
variable USER_LIBS, automatically detect GnuTLS.  Copies the PNG
library setup with trivial modifications.
* nt/INSTALL: Add instructions for GnuTLS support.
* nt/gmake.defs: Prefix USER_LIBS with -l.

13 years agoAdd GnuTLS support for W32.
Ted Zlatanov [Mon, 25 Apr 2011 01:28:55 +0000 (20:28 -0500)]
Add GnuTLS support for W32.

* lib-src/makefile.w32-in (obj): Added gnutls.o.

13 years ago* progmodes/cc-engine.el (c-forward-decl-or-cast-1): Use
Daniel Colascione [Mon, 25 Apr 2011 00:31:41 +0000 (17:31 -0700)]
* progmodes/cc-engine.el (c-forward-decl-or-cast-1): Use
correct match group (bug#8438).

13 years agoshr.el (shr-tag-sup, shr-tag-sub): New functions.
Lars Magne Ingebrigtsen [Sun, 24 Apr 2011 22:12:21 +0000 (22:12 +0000)]
shr.el (shr-tag-sup, shr-tag-sub): New functions.

13 years agoRestore ability to show a restricted list of packages in Package Menu.
Chong Yidong [Sun, 24 Apr 2011 20:32:23 +0000 (16:32 -0400)]
Restore ability to show a restricted list of packages in Package Menu.

* emacs-lisp/package.el (package-built-in-p): Fix typo.
(package-menu--generate): New arg specifying packages to show.
(package-menu-refresh, package-menu-execute, list-packages):
Callers changed.
(package-show-package-list): New function.

* finder.el (finder-list-matches): Use package-show-package-list
instead of deleted package--list-packages.

13 years agoAdd vc-annotate-goto-line.
Chong Yidong [Sun, 24 Apr 2011 19:37:47 +0000 (15:37 -0400)]
Add vc-annotate-goto-line.
* vc/vc-annotate.el (vc-annotate-goto-line): New command.  Based
on a previous implementation by Juanma Barranquero (Bug#8366).
(vc-annotate-mode-map): Bind it to RET.

13 years agoFix next-file command in etags.el.
Uday S Reddy [Sun, 24 Apr 2011 18:47:17 +0000 (14:47 -0400)]
Fix next-file command in etags.el.

* lisp/progmodes/etags.el (next-file): Don't use set-buffer to change
buffers (Bug#8478).

* doc/lisp/maintaining.texi (List Tags): Document next-file.

13 years agoRevert undocumented change to .dir-locals.el in 2011-04-01T17:19:52Z!monnier@iro...
Chong Yidong [Sun, 24 Apr 2011 18:34:57 +0000 (14:34 -0400)]
Revert undocumented change to .dir-locals.el in 2011-04-01T17:19:52Z!monnier@iro.umontreal.ca.

This bumped fill-column from 70 to 79, but was not documented in the
commit log, and appears to be a mistake.

13 years agoMinor cleanup in src/xdisp.c.
Eli Zaretskii [Sun, 24 Apr 2011 16:59:37 +0000 (19:59 +0300)]
Minor cleanup in src/xdisp.c.

 src/xdisp.c (handle_single_display_spec): Rename the
 display_replaced_before_p argument into display_replaced_p, to
 make it consistent with the commentary.  Fix typos in the
 commentary.

13 years agoMinor cleanup in src/textprop.c.
Eli Zaretskii [Sun, 24 Apr 2011 16:28:57 +0000 (19:28 +0300)]
Minor cleanup in src/textprop.c.

 src/textprop.c (syms_of_textprop): Remove dead code.
 (copy_text_properties): Delete obsolete commentary about an
 interface that was deleted long ago.  Fix typos in the description
 of arguments.

13 years agoRepair the MSDOS build following latest changes.
Eli Zaretskii [Sun, 24 Apr 2011 12:48:30 +0000 (15:48 +0300)]
Repair the MSDOS build following latest changes.

 msdos/sedlibmk.inp (am_libgnu_a_OBJECTS): Edit out
 allocator.$(OBJEXT).  Add editing for the new GNULIB_* and
 REPLACE_* variables.
 src/msdos.c (XMenuActivate, XMenuAddSelection): Adjust argument list
 to changes in oldXMenu/XMenu.h from 2011-04-16.
 <menu_help_message, prev_menu_help_message>: Constify.
 (IT_menu_make_room): menu->help_text is now `const char **';
 adjust.
 src/msdos.h (XMenuActivate, XMenuAddSelection): Adjust prototypes
 to changes in oldXMenu/XMenu.h from 2011-04-16.
 (struct XMenu): Declare `help_text' `const char **'.
 src/xfaces.c <Qunspecified>: Make extern again.
 src/syntax.c: Include sys/types.h before including regex.h, as
 required by Posix.

13 years agoFallout from resurrecting doprnt.
Eli Zaretskii [Sun, 24 Apr 2011 09:00:03 +0000 (12:00 +0300)]
Fallout from resurrecting doprnt.

 src/doc.c (get_doc_string): Improve the format passed to `error'.
 src/doprnt.c (doprnt): Improve commentary.
 src/term.c (init_tty) [MSDOS]: Fix 1st argument to maybe_fatal.
 src/Makefile.in (TAGS): Depend on $(M_FILE) and $(S_FILE), and scan
 them with etags.
 src/makefile.w32-in (TAGS): Depend on $(CURDIR)/m/intel386.h and
 $(CURDIR)/s/ms-w32.h.
 (TAGS-gmake): Scan $(CURDIR)/m/intel386.h and $(CURDIR)/s/ms-w32.h.

13 years agoFix a minor bug in src/makefile.w32-in.
Eli Zaretskii [Sun, 24 Apr 2011 07:15:17 +0000 (10:15 +0300)]
Fix a minor bug in src/makefile.w32-in.

 src/makefile.w32-in (globals.h): Add a dummy recipe, to make any
 changes in globals.h immediately force recompilation.

13 years agoDelete char-direction-table and char-direction.
Eli Zaretskii [Sun, 24 Apr 2011 07:11:56 +0000 (10:11 +0300)]
Delete char-direction-table and char-direction.

 See http://lists.gnu.org/archive/html/emacs-devel/2011-04/msg00675.html
 for the reasons.

 src/character.c (Fchar_direction): Function deleted.
 (syms_of_character): Don't defsubr it.
 <char-direction-table>: Deleted.
 etc/NEWS: Document the removal.

13 years ago* bytecode.c (exec_byte_code): Don't use XVECTOR before CHECK_VECTOR.
Paul Eggert [Sun, 24 Apr 2011 05:30:24 +0000 (22:30 -0700)]
* bytecode.c (exec_byte_code): Don't use XVECTOR before CHECK_VECTOR.

13 years ago* files.el (auto-mode-alist): Use js-mode for .json (Bug#8529).
Chong Yidong [Sun, 24 Apr 2011 00:24:30 +0000 (20:24 -0400)]
* files.el (auto-mode-alist): Use js-mode for .json (Bug#8529).

13 years agoImprove apropos buffer highlighting.
Chong Yidong [Sun, 24 Apr 2011 00:15:26 +0000 (20:15 -0400)]
Improve apropos buffer highlighting.

* lisp/apropos.el (apropos-label-face): Avoid variable-pitch face.
(apropos-accumulator): Doc fix.
(apropos-function, apropos-macro, apropos-command)
(apropos-variable, apropos-face, apropos-group, apropos-widget)
(apropos-plist): Add face property.
(apropos-symbols-internal): Fix indentation.
(apropos-print): Simplify help, and recognize apropos-multi-type.
(apropos-print-doc): Use button-type-get to extract the button's
face property.  Fill docstring (Bug#8352).

13 years agoFix typos in comments in character.c and textprop.c.
Eli Zaretskii [Sat, 23 Apr 2011 17:19:56 +0000 (20:19 +0300)]
Fix typos in comments in character.c and textprop.c.

13 years agoFix doprnt so it could be used safely in `verror'. (Bug#8435)
Eli Zaretskii [Sat, 23 Apr 2011 10:33:28 +0000 (13:33 +0300)]
Fix doprnt so it could be used safely in `verror'.  (Bug#8435)

 src/doprnt.c: Include limits.h.
 (SIZE_MAX): New macro.
 (doprnt): Return a size_t value.  2nd arg is now size_t.  Many
 local variables are now size_t instead of int or unsigned.
 Improve overflow protection.  Support `l' modifier for integer
 conversions.  Support %l conversion.  Don't assume an EMACS_INT
 argument for integer conversions and for %c.
 src/lisp.h (doprnt): Restore prototype.
 src/makefile.w32-in ($(BLD)/callint.$(O)): Depend on
 $(SRC)/character.h.
 src/Makefile.in (base_obj): Add back doprnt.o.
 src/deps.mk (doprnt.o): Add back prerequisites.
 (callint.o): Depend on character.h.
 src/eval.c (internal_lisp_condition_case): Include the handler
 representation in the error message.
 (verror): Call doprnt instead of vsnprintf.  Fix an off-by-one bug
 when breaking from the loop.
 src/xdisp.c (vmessage): Call doprnt instead of vsnprintf.
 src/callint.c (Fcall_interactively): When displaying error message
 about invalid control letter, pass the character's codepoint, not
 a pointer to its multibyte form.  Improve display of the character
 in octal and display also its hex code.
 src/character.c (char_string): Use %x to display the (unsigned)
 codepoint of an invalid character, to avoid displaying a bogus
 negative value.
 src/font.c (check_otf_features): Pass SDATA of SYMBOL_NAME to
 `error', not SYMBOL_NAME itself.
 src/coding.c (Fencode_sjis_char, Fencode_big5_char): Use %c for
 character arguments to `error'.
 src/charset.c (check_iso_charset_parameter): Fix incorrect argument
 to `error' in error message about FINAL_CHAR argument.  Make sure
 FINAL_CHAR is a character, and use %c when it is passed as
 argument to `error'.

13 years agoMerge from emacs-23; up to 2010-06-09T17:54:28Z!albinus@detlef.
Glenn Morris [Sat, 23 Apr 2011 03:07:16 +0000 (20:07 -0700)]
Merge from emacs-23; up to 2010-06-09T17:54:28Z!albinus@detlef.

13 years ago* lisp/gnus/gnus-sum.el (gnus-extra-headers): Bump :version.
Glenn Morris [Sat, 23 Apr 2011 02:18:10 +0000 (19:18 -0700)]
* lisp/gnus/gnus-sum.el (gnus-extra-headers): Bump :version.

13 years agoRevert incorrect change to copyright years.
Glenn Morris [Sat, 23 Apr 2011 02:15:03 +0000 (19:15 -0700)]
Revert incorrect change to copyright years.

13 years agognus-registry.el (gnus-registry-ignore-group-p): Test specifically for the case where...
Teodor Zlatanov [Sat, 23 Apr 2011 00:08:28 +0000 (00:08 +0000)]
gnus-registry.el (gnus-registry-ignore-group-p): Test specifically for the case where `gnus-registry-ignored-groups' is a list of lists, and don't call `gnus-parameter-registry-ignore' otherwise.

13 years agoMerge from gnulib.
Paul Eggert [Fri, 22 Apr 2011 23:53:21 +0000 (16:53 -0700)]
Merge from gnulib.

13 years agoAdd trailing underscores to appropriate member names, per change 2011-02-14T15:39...
Noah Friedman [Fri, 22 Apr 2011 23:29:02 +0000 (16:29 -0700)]
Add trailing underscores to appropriate member names, per change 2011-02-14T15:39:19Z!tromey@redhat.com of src/lisp.h.

13 years agolisp/eshell/esh-mode.el (find-tag-interactive): Small cleanup.
Juanma Barranquero [Fri, 22 Apr 2011 20:15:21 +0000 (22:15 +0200)]
lisp/eshell/esh-mode.el (find-tag-interactive): Small cleanup.

* eshell/esh-mode.el (find-tag-interactive): Declare function.
  (eshell-find-tag): Remove `with-no-warnings', unneeded now.
  Pass argument NO-DEFAULT to `find-tag-interactive'.

13 years agolisp/buff-menu.el (Buffer-menu--buffers): Fix typo in docstring.
Juanma Barranquero [Fri, 22 Apr 2011 18:49:58 +0000 (20:49 +0200)]
lisp/buff-menu.el (Buffer-menu--buffers): Fix typo in docstring.

Fixes: debbugs:8535

13 years agolisp/progmodes/*.el: Lexical-binding cleanup.
Juanma Barranquero [Fri, 22 Apr 2011 18:44:26 +0000 (20:44 +0200)]
lisp/progmodes/*.el: Lexical-binding cleanup.

13 years agoMerge from gnulib.
Paul Eggert [Fri, 22 Apr 2011 09:31:24 +0000 (02:31 -0700)]
Merge from gnulib.

13 years ago* configure.in: Suppress unnecessary checks for size_t.
Paul Eggert [Fri, 22 Apr 2011 07:36:41 +0000 (00:36 -0700)]
* configure.in: Suppress unnecessary checks for size_t.

(AC_TYPE_SIZE_T): Define an empty macro, to suppress obsolescent test.
(size_t): Do not check for this, and do not typedef.  This code
is never exercised now.

13 years ago* .bzrignore: Add lib/inttypes.h.
Paul Eggert [Fri, 22 Apr 2011 07:34:26 +0000 (00:34 -0700)]
* .bzrignore: Add lib/inttypes.h.

13 years agoSimpler version of strtoumax module.
Paul Eggert [Fri, 22 Apr 2011 07:33:37 +0000 (00:33 -0700)]
Simpler version of strtoumax module.

13 years agoDoc fixes for package.el.
Chong Yidong [Fri, 22 Apr 2011 02:35:48 +0000 (22:35 -0400)]
Doc fixes for package.el.

* emacs-lisp/package.el (package--builtins, package-alist)
(package-load-descriptor, package-built-in-p, package-activate)
(define-package, package-installed-p)
(package-compute-transaction, package-buffer-info)
(package--push): Doc fix.  Distinguish more clearly between
version strings and version lists.

13 years agonnimap.el (nnimap-user): New backend variable.
Teodor Zlatanov [Fri, 22 Apr 2011 01:01:32 +0000 (01:01 +0000)]
nnimap.el (nnimap-user): New backend variable.
 (nnimap-open-connection-1): Use it.
 (nnimap-credentials): Accept user parameter so it's explicit what user name is desired.

13 years agognus-sum.el (gnus-extra-headers): Add Keywords, Cc, and Gcc to default.
Teodor Zlatanov [Fri, 22 Apr 2011 00:37:01 +0000 (00:37 +0000)]
gnus-sum.el (gnus-extra-headers): Add Keywords, Cc, and Gcc to default.
gnus-registry.el: Mention in comments how to modify `gnus-extra-headers' for proper recipient tracking and that it may already have To and Cc recently, which it does as of this commit.

13 years ago* lib/wchar.h, lib/inttypes.h: Remove; not needed.
Paul Eggert [Thu, 21 Apr 2011 23:19:06 +0000 (16:19 -0700)]
* lib/wchar.h, lib/inttypes.h: Remove; not needed.

13 years agognus.el (gnus-registry-ignored-groups): Provide default in gnus.el, not gnus-registry.el.
Teodor Zlatanov [Thu, 21 Apr 2011 22:06:12 +0000 (22:06 +0000)]
gnus.el (gnus-registry-ignored-groups): Provide default in gnus.el, not gnus-registry.el.
gnus-registry.el (gnus-registry-ignored-groups): Remove defcustom.  Explain why in comments.
 (gnus-registry-action): Fix data-header reference to use the extra headers.  Explain in package commentary how to add To and Cc headers to the gnus-extra-headers.
 (gnus-registry-ignored-groups): Adjust defaults to match the parameter.
 (gnus-registry-ignore-group-p): Adjust to take either a group/topic parameter list or a string list in `gnus-registry-ignored-groups'.  Fix logic error.

13 years agostrtoimax -> strtoumax, fixing a typo.
Paul Eggert [Thu, 21 Apr 2011 19:40:13 +0000 (12:40 -0700)]
strtoimax -> strtoumax, fixing a typo.

13 years agoRemove empty line.
Paul Eggert [Thu, 21 Apr 2011 19:15:37 +0000 (12:15 -0700)]
Remove empty line.

13 years ago* Makefile.in (GNULIB_MODULES): Add strtoumax.
Paul Eggert [Thu, 21 Apr 2011 19:12:13 +0000 (12:12 -0700)]
* Makefile.in (GNULIB_MODULES): Add strtoumax.

13 years ago* lread.c (string_to_number): Use strtoumax, to convert more integers without overflow.
Paul Eggert [Thu, 21 Apr 2011 18:57:37 +0000 (11:57 -0700)]
* lread.c (string_to_number): Use strtoumax, to convert more integers without overflow.

13 years agolisp/play/*.el: Lexical-binding cleanup.
Juanma Barranquero [Thu, 21 Apr 2011 12:24:46 +0000 (14:24 +0200)]
lisp/play/*.el: Lexical-binding cleanup.

13 years agolisp/play/mpuz.el: Small fixes.
Juanma Barranquero [Thu, 21 Apr 2011 12:06:01 +0000 (14:06 +0200)]
lisp/play/mpuz.el: Small fixes.

* play/mpuz (mpuz-silent): Doc fix.
  (mpuz-mode-map): Move initialization into declaration.
  (mpuz-put-number-on-board): Rename parameter L to COLUMNS.
  (mpuz-letter-to-digit, mpuz-check-all-solved, mpuz-create-buffer):
  Fix typos in docstrings.

13 years agoTreat large integers as floats in the Lisp reader and in string-to-number.
Paul Eggert [Thu, 21 Apr 2011 06:03:09 +0000 (23:03 -0700)]
Treat large integers as floats in the Lisp reader and in string-to-number.

13 years agoshr.el (shr-expand-url): Fix typo.
Katsumi Yamaoka [Thu, 21 Apr 2011 02:48:04 +0000 (02:48 +0000)]
shr.el (shr-expand-url): Fix typo.

13 years agolisp/play/doctor.el: Fix typos in docstrings.
Juanma Barranquero [Thu, 21 Apr 2011 02:45:31 +0000 (04:45 +0200)]
lisp/play/doctor.el: Fix typos in docstrings.

13 years agoshr.el (shr-expand-url): Protect against null urls.
Lars Magne Ingebrigtsen [Thu, 21 Apr 2011 02:22:56 +0000 (02:22 +0000)]
shr.el (shr-expand-url): Protect against null urls.

13 years agoshr.el (shr-base): New binding.
Lars Magne Ingebrigtsen [Thu, 21 Apr 2011 00:24:27 +0000 (00:24 +0000)]
shr.el (shr-base): New binding.
 (shr-tag-base): Keep track of <base>.
 (shr-expand-url): New function used throughout.

13 years agolisp/vc/vc.el (ediff-vc-internal): Declare function.
Juanma Barranquero [Wed, 20 Apr 2011 23:34:00 +0000 (01:34 +0200)]
lisp/vc/vc.el (ediff-vc-internal): Declare function.

13 years ago* lisp/shell.el: Use lexical-binding and std completion UI.
Stefan Monnier [Wed, 20 Apr 2011 22:31:06 +0000 (19:31 -0300)]
* lisp/shell.el: Use lexical-binding and std completion UI.
(shell-filter-ctrl-a-ctrl-b): Work as a preoutput filter.
(shell-mode): Put shell-filter-ctrl-a-ctrl-b on
comint-preoutput-filter-functions rather than on
comint-output-filter-functions.
(shell-command-completion, shell--command-completion-data)
(shell-filename-completion, shell-environment-variable-completion)
(shell-c-a-p-replace-by-expanded-directory): New functions.
(shell-dynamic-complete-functions, shell-dynamic-complete-command)
(shell-dynamic-complete-filename, shell-replace-by-expanded-directory)
(shell-dynamic-complete-environment-variable): Use them.
(shell-dynamic-complete-as-environment-variable)
(shell-dynamic-complete-as-command): Remove.
(shell-match-partial-variable): Match past point.
* lisp/comint.el: Clean up use of completion-at-point-functions.
(comint-completion-at-point): New function.
(comint-mode): Use it completion-at-point-functions.
(comint-dynamic-complete): Make it obsolete.
(comint-replace-by-expanded-history-before-point): Add dry-run arg.
(comint-c-a-p-replace-by-expanded-history): New function.
(comint-dynamic-complete-functions)
(comint-replace-by-expanded-history): Use it.
* lisp/minibuffer.el (completion-table-with-terminator): Allow dynamic
termination strings.  Try harder to avoid second try-completion.
(completion-in-region-mode-map): Disable bindings that don't work yet.

13 years agognus-registry.el (gnus-registry--split-fancy-with-parent-internal): Fix loop bugs.
Teodor Zlatanov [Wed, 20 Apr 2011 22:12:08 +0000 (22:12 +0000)]
gnus-registry.el (gnus-registry--split-fancy-with-parent-internal): Fix loop bugs.
 (gnus-registry-ignored-groups): New variable.
 (gnus-registry-ignore-group-p): Use it.
 (gnus-registry-handle-action): Use `gnus-registry-ignore-group-p' and set the destination group to nil (same as delete) if it's ignored.

13 years ago* lisp/comint.el: Use lexical-binding. Use std completion UI. Require CL.
Stefan Monnier [Wed, 20 Apr 2011 19:05:50 +0000 (16:05 -0300)]
* lisp/comint.el: Use lexical-binding.  Use std completion UI.  Require CL.
(comint-dynamic-complete-functions): Use comint-filename-completion.
(comint-completion-addsuffix): Tweak custom type.
(comint-filename-completion, comint--common-suffix)
(comint--common-quoted-suffix, comint--table-subvert)
(comint--complete-file-name-data): New functions.
(comint-dynamic-complete-as-filename, comint-dynamic-complete-filename)
(comint-dynamic-list-filename-completions): Use them.
(comint-dynamic-simple-complete): Make obsolete.
* lisp/minibuffer.el (completion-in-region-mode):
Keep completion-in-region-mode--predicate global.
(completion-in-region--postch):
Assume completion-in-region-mode--predicate is not null.

13 years ago* lisp/progmodes/flymake.el (flymake-start-syntax-check-process): Obey `dir'.
Stefan Monnier [Wed, 20 Apr 2011 18:08:21 +0000 (15:08 -0300)]
* lisp/progmodes/flymake.el (flymake-start-syntax-check-process): Obey `dir'.

13 years ago* lisp/vc/vc.el (vc-version-ediff): Call ediff-vc-internal directly, since
Stefan Monnier [Wed, 20 Apr 2011 17:39:39 +0000 (14:39 -0300)]
* lisp/vc/vc.el (vc-version-ediff): Call ediff-vc-internal directly, since
we're in VC after all.

13 years ago* lisp/vc/vc.el (vc-diff-build-argument-list-internal)
Christoph Scholtes [Wed, 20 Apr 2011 17:33:09 +0000 (14:33 -0300)]
* lisp/vc/vc.el (vc-diff-build-argument-list-internal)
(vc-version-ediff, vc-ediff): New functions.
(vc-version-diff): Use vc-diff-build-argument-list-internal.
* doc/emacs/maintaining.texi (Old Revisions): Add paragraph on new function
vc-ediff.
* etc/NEWS: Document new function `vc-ediff'.

13 years ago* lisp/emacs-lisp/byte-opt.el (byte-decompile-bytecode-1): Remove dead code,
Stefan Monnier [Wed, 20 Apr 2011 17:28:07 +0000 (14:28 -0300)]
* lisp/emacs-lisp/byte-opt.el (byte-decompile-bytecode-1): Remove dead code,
add sanity check.

13 years ago* Makefile.in (config.status): Don't erase in case of error.
Stefan Monnier [Wed, 20 Apr 2011 17:23:30 +0000 (14:23 -0300)]
* Makefile.in (config.status): Don't erase in case of error.
In case it disappeared, rebuild it with `configure'.

13 years ago* lisp/obsolete/erc-hecomplete.el: Make obsolete.
Stefan Monnier [Wed, 20 Apr 2011 17:18:34 +0000 (14:18 -0300)]
* lisp/obsolete/erc-hecomplete.el: Make obsolete.
* obsolete/: Standardize obsolescence info in the header.

13 years agoAuto-commit of loaddefs files.
Glenn Morris [Wed, 20 Apr 2011 10:23:12 +0000 (06:23 -0400)]
Auto-commit of loaddefs files.