]> git.eshelyaron.com Git - emacs.git/log
emacs.git
11 years agoMerge pull request #7 from daimrod/fix-image-mode-interaction
Joakim Verona [Thu, 18 Jul 2013 20:14:17 +0000 (13:14 -0700)]
Merge pull request #7 from daimrod/fix-image-mode-interaction

Fix image mode interaction

11 years agoMerge pull request #9 from daimrod/quickfix-cairo-view
Joakim Verona [Thu, 18 Jul 2013 20:12:45 +0000 (13:12 -0700)]
Merge pull request #9 from daimrod/quickfix-cairo-view

* src/xwidget.c (xwidget_init_view): Prevent an error while displaying a

11 years ago* lisp/xwidget.el: Fix the interaction between `image-mode' and xwidget.
Grégoire Jadi [Thu, 18 Jul 2013 17:54:12 +0000 (19:54 +0200)]
* lisp/xwidget.el: Fix the interaction between `image-mode' and xwidget.
(xwidget-image-mode-navigation-adaptor
xwidget-image-mode-navigation-adaptor-p): `flet' has been deprecated and
`cl-flet' doesn't work like the old `flet', we now use a `defadvice'
around `image-display-size' instead.
(xwidget-webkit-mode-map): No need to use the adaptators now.

11 years ago* src/xwidget.c (xwidget_init_view): Prevent an error while displaying a
Grégoire Jadi [Thu, 18 Jul 2013 17:51:36 +0000 (19:51 +0200)]
* src/xwidget.c (xwidget_init_view): Prevent an error while displaying a
xwidget of type `cairo' but doesn't do anything useful.

11 years ago* test/automated/test-xwidget.el: Add XWidget test suites.
Grégoire Jadi [Thu, 18 Jul 2013 12:12:04 +0000 (14:12 +0200)]
* test/automated/test-xwidget.el: Add XWidget test suites.

11 years ago* src/xwidget.c (Fset_frame_visible): Hack to force a frame to be
Grégoire Jadi [Thu, 18 Jul 2013 12:12:03 +0000 (14:12 +0200)]
* src/xwidget.c (Fset_frame_visible): Hack to force a frame to be
considered as visible to trigger the display engine.
* lisp/xwidget.el (xwidget-display): Force the display engine to create a
xwidget_view of the given xwidget.

11 years ago* lisp/emacs-parallel/parallel.el lisp/emacs-parallel/parallel-remote.el:
Grégoire Jadi [Thu, 18 Jul 2013 12:12:03 +0000 (14:12 +0200)]
* lisp/emacs-parallel/parallel.el lisp/emacs-parallel/parallel-remote.el:
Add Emacs Parallel.

11 years ago* src/xwidget.h (xwidget): Remove old todo.
Grégoire Jadi [Thu, 18 Jul 2013 09:48:15 +0000 (11:48 +0200)]
* src/xwidget.h (xwidget): Remove old todo.

11 years ago* src/xwidget.c (Fxwidget_info): Fix a regression introduced in commit
Grégoire Jadi [Thu, 18 Jul 2013 09:48:14 +0000 (11:48 +0200)]
* src/xwidget.c (Fxwidget_info): Fix a regression introduced in commit
b4e1725be1b96b5335a12d34fdd81b99dededf54.

11 years ago* src/xwidget.c (Fxwidget_delete_zombies): Re-implemented in Lisp.
Grégoire Jadi [Thu, 18 Jul 2013 09:48:13 +0000 (11:48 +0200)]
* src/xwidget.c (Fxwidget_delete_zombies): Re-implemented in Lisp.
Note: It is not longer necessary to delete xwidget with killed buffer
here because it is done automatically when a buffer is killed.
(Fdelete_xwidget_view): New function to delete the given
xwidget-view.
* lisp/xwidget.el (xwidget-delete-zombies): Re-implementation.
* src/xwidget.c (Fxwidget_delete_zombies): Re-implemented in Lisp. Note: It is not longer necessary to delete xwidget with killed buffer here because it is done automatically when a buffer is killed. (Fdelete_xwidget_view): New function to delete the given xwidget-view. * lisp/xwidget.el (xwidget-delete-zombies): New implementation.

11 years ago* src/xwidget.c (Fmake_xwidget): Set the initial value of `query-on-exit'
Grégoire Jadi [Tue, 16 Jul 2013 17:39:21 +0000 (19:39 +0200)]
* src/xwidget.c (Fmake_xwidget): Set the initial value of `query-on-exit'
flag to t (kill_without_query = !query-on-exit).

11 years ago* src/xwidget.c: Add a `query-on-exit' flag to determine whether we can
Grégoire Jadi [Tue, 16 Jul 2013 17:39:20 +0000 (19:39 +0200)]
* src/xwidget.c: Add a `query-on-exit' flag to determine whether we can
kill xwidget when the buffer is killed without confirmation.
(Fset_xwidget_query_on_exit_flag): New function to set the `query-on-exit'
flag.
(Fxwidget_query_on_exit_flag): New function to retrieve the value of the
`query-on-exit' flag.
(Fmake_xwidget): Set the `query-on-exit' flag to t by default.
* src/xwidget.h (xwidget): Add new field `kill_without_query'.
* lisp/xwidget.el (xwidget-kill-buffer-query-function): Ask for
confirmation before killing the buffer if a xwidget is present only if its
`query-on-exit' flag is enabled.

11 years ago* src/xwidget.c (kill_buffer_xwidgets): Cleanup OSR GtkWidget when xwidget
Grégoire Jadi [Tue, 16 Jul 2013 17:39:19 +0000 (19:39 +0200)]
* src/xwidget.c (kill_buffer_xwidgets): Cleanup OSR GtkWidget when xwidget
are freed.

11 years ago* src/xwidget.c (Fxwidget_view_lookup): Bring `xwidget-view-lookup' to the
Grégoire Jadi [Tue, 16 Jul 2013 17:39:19 +0000 (19:39 +0200)]
* src/xwidget.c (Fxwidget_view_lookup): Bring `xwidget-view-lookup' to the
Lisp side.
(xwidget_view_lookup): `xwidget_view_lookup' is just a wrapper around
`xwidget-view-lookup' to convert from `struct *' to `Lisp_Object'.

11 years ago* src/xwidget.c (Fxwidget_view_model, Fxwidget_view_window): Add accessors
Grégoire Jadi [Tue, 16 Jul 2013 17:39:19 +0000 (19:39 +0200)]
* src/xwidget.c (Fxwidget_view_model, Fxwidget_view_window): Add accessors
to xwidget_view components.

11 years ago* src/xwidget.c: Fix indentation.
Grégoire Jadi [Tue, 16 Jul 2013 17:39:18 +0000 (19:39 +0200)]
* src/xwidget.c: Fix indentation.

11 years ago* src/xwidget.h src/xwidget.c (valid_xwidget_spec_p): Renamed
Grégoire Jadi [Tue, 16 Jul 2013 17:39:18 +0000 (19:39 +0200)]
* src/xwidget.h src/xwidget.c (valid_xwidget_spec_p): Renamed
`valid_xwidget_p' to `valid_xwidget_p'.
(XWIDGETP): Rename `XXWIDGETP' to `XWIDGETP' and `XXWIDGET_VIEW_P' to
`XWIDGET_VIEW_P'. The old `XWIDGETP' is now implemented solely in
`valid_xwidget_spec_p'.
(CHECK_XWIDGET): New macro to check whether the argument is a xwidget.
(CHECK_XWIDGET_VIEW): New macro to check whether the argument is a
xwidget_view.
* src/print.c src/xdisp.c: Take into account the new names.

11 years ago* src/print.c (print_object): Add pretty printing for xwidget_view.
Grégoire Jadi [Tue, 16 Jul 2013 17:39:18 +0000 (19:39 +0200)]
* src/print.c (print_object): Add pretty printing for xwidget_view.

11 years agoMerge branch 'trunk' into xwidget
Joakim Verona [Sun, 14 Jul 2013 09:04:49 +0000 (11:04 +0200)]
Merge branch 'trunk' into xwidget

Conflicts:
src/xdisp.c

11 years agoSpelling fixes.
Paul Eggert [Sun, 14 Jul 2013 05:18:48 +0000 (22:18 -0700)]
Spelling fixes.

11 years ago* callproc.c (child_setup, relocate_fd) [!DOS_NT]:
Paul Eggert [Sun, 14 Jul 2013 00:30:45 +0000 (17:30 -0700)]
* callproc.c (child_setup, relocate_fd) [!DOS_NT]:

* process.c (create_process) [!DOS_NT]:
Remove now-unnecessary calls to emacs_close.

11 years ago* lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Highlight
Dmitry Gutov [Sat, 13 Jul 2013 19:10:19 +0000 (23:10 +0400)]
* lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Highlight
conversion methods on Kernel.

11 years agoprogmodes/cc-engine.el (c-forward-decl-or-cast-1): Label CASE 13
Alan Mackenzie [Sat, 13 Jul 2013 17:45:07 +0000 (17:45 +0000)]
progmodes/cc-engine.el (c-forward-decl-or-cast-1): Label CASE 13
and comment it out.  This out-commenting enables certain C++
declarations to be parsed correctly.

11 years agoPrevent leak in GDI objects (bug #14850).
Eli Zaretskii [Sat, 13 Jul 2013 14:21:01 +0000 (17:21 +0300)]
Prevent leak in GDI objects (bug #14850).

 src/w32term.c (x_draw_hollow_cursor): Delete the brush object when
 returning early.

11 years agoImprove the documentation of prefer-utf-8 and related issues.
Eli Zaretskii [Sat, 13 Jul 2013 10:55:21 +0000 (13:55 +0300)]
Improve the documentation of prefer-utf-8 and related issues.

 lisp/international/mule.el (define-coding-system): Doc fix.

 etc/NEWS: Document prefer-utf-8 coding-system and the new attributes
 :inhibit-null-byte-detection, :inhibit-iso-escape-detection, and
 :prefer-utf-8.

11 years agoFix bug #14822 with decoding when inhibit-null-byte-detection is non-nil.
Eli Zaretskii [Sat, 13 Jul 2013 10:29:15 +0000 (13:29 +0300)]
Fix bug #14822 with decoding when inhibit-null-byte-detection is non-nil.

 src/coding.c (syms_of_coding): Set up inhibit-null-byte-detection
 and inhibit-iso-escape-detection attributes of 'undecided'.

11 years agoAuto-commit of generated files.
Glenn Morris [Sat, 13 Jul 2013 10:17:35 +0000 (06:17 -0400)]
Auto-commit of generated files.

11 years ago* deps.mk (sysdep.o): Remove dependency on ../lib/ignore-value.h.
Paul Eggert [Sat, 13 Jul 2013 09:32:45 +0000 (02:32 -0700)]
* deps.mk (sysdep.o): Remove dependency on ../lib/ignore-value.h.

Reported by Herbert J. Skuhra in
<http://lists.gnu.org/archive/html/emacs-devel/2013-07/msg00455.html>.

11 years agoFix bug #14838 with slow scrolling with certain fonts.
Eli Zaretskii [Sat, 13 Jul 2013 07:26:43 +0000 (10:26 +0300)]
Fix bug #14838 with slow scrolling with certain fonts.

 lisp/simple.el (default-font-height): Don't call font-info if the
 frame's default font didn't change since the frame was created.

11 years ago* ido.el (ido-read-file-name): Guard against non-symbol value.
Leo Liu [Sat, 13 Jul 2013 04:44:19 +0000 (12:44 +0800)]
* ido.el (ido-read-file-name): Guard against non-symbol value.

11 years ago* lisp/progmodes/python.el (python-imenu--build-tree): Fix corner case
Fabián Ezequiel Gallina [Sat, 13 Jul 2013 01:55:58 +0000 (22:55 -0300)]
* lisp/progmodes/python.el (python-imenu--build-tree): Fix corner case
in nested defuns.

* test/automated/python-tests.el (python-imenu-create-index-2)
(python-imenu-create-index-3): New tests.

11 years ago* NEWS: Mention new value for ido-use-virtual-buffers.
Leo Liu [Sat, 13 Jul 2013 01:30:36 +0000 (09:30 +0800)]
* NEWS: Mention new value for ido-use-virtual-buffers.

11 years ago* ido.el (ido-exhibit): Handle ido-enter-matching-directory before
Leo Liu [Sat, 13 Jul 2013 00:57:47 +0000 (08:57 +0800)]
* ido.el (ido-exhibit): Handle ido-enter-matching-directory before
ido-set-matches call.

Fixes: debbugs:6852
11 years agoDon't lose top specpdl entry when memory is exhausted.
Paul Eggert [Sat, 13 Jul 2013 00:24:38 +0000 (17:24 -0700)]
Don't lose top specpdl entry when memory is exhausted.

* eval.c (grow_specpdl): Increment specpdl top by 1 and check for
specpdl overflow here, to simplify callers; all callers changed.
Always reserve an unused entry at the stack top; this avoids
losing the top entry's information when memory is exhausted.

11 years ago* configure.ac: Simplify --with-file-notification handling.
Paul Eggert [Sat, 13 Jul 2013 00:01:43 +0000 (17:01 -0700)]
* configure.ac: Simplify --with-file-notification handling.

11 years agoChangeLog fix
Glenn Morris [Fri, 12 Jul 2013 23:55:01 +0000 (19:55 -0400)]
ChangeLog fix

11 years ago* progmodes/ruby-mode.el (ruby-font-lock-keywords): Simplify the last
Dmitry Gutov [Fri, 12 Jul 2013 23:36:14 +0000 (03:36 +0400)]
* progmodes/ruby-mode.el (ruby-font-lock-keywords): Simplify the last
  change.

11 years ago* configure.ac: Further fix.
Glenn Morris [Fri, 12 Jul 2013 23:15:20 +0000 (19:15 -0400)]
* configure.ac: Further fix.

11 years ago* configure.ac: Fix goofs in previous.
Glenn Morris [Fri, 12 Jul 2013 23:14:20 +0000 (19:14 -0400)]
* configure.ac: Fix goofs in previous.

11 years ago* lisp/progmodes/ruby-mode.el (ruby-percent-literals-beg-re):
Dmitry Gutov [Fri, 12 Jul 2013 20:28:53 +0000 (00:28 +0400)]
* lisp/progmodes/ruby-mode.el (ruby-percent-literals-beg-re):
(ruby-syntax-expansion-allowed-p): Support array of symbols, for
Ruby 2.0.
(ruby-font-lock-keywords): Distinguish calls to functions with
module-like names from module references.  Highlight character
literals.

11 years agoFix last lisp/ChangeLog entry.
Sergio Durigan Junior [Fri, 12 Jul 2013 18:19:10 +0000 (21:19 +0300)]
Fix last lisp/ChangeLog entry.

Fixes: debbugs:14847
11 years agoFix bug #14847 with continued GDB command lines in gdb-mi.el.
Sergio Durigan Junior [Fri, 12 Jul 2013 18:17:17 +0000 (21:17 +0300)]
Fix bug #14847 with continued GDB command lines in gdb-mi.el.

 lisp/progmodes/gdb-mi.el (gdb-strip-string-backslash): New function.
 (gdb-send): Handle continued commands.

11 years ago* configure.ac: If with-file-notification=yes, if gfile not found,
Glenn Morris [Fri, 12 Jul 2013 17:36:42 +0000 (13:36 -0400)]
* configure.ac: If with-file-notification=yes, if gfile not found,
go on to try inotify (not on MS Windows or Nextstep).

* etc/NEWS: Copyedits.

11 years agoClean up errno reporting and fix some errno-reporting bugs.
Paul Eggert [Fri, 12 Jul 2013 17:30:48 +0000 (10:30 -0700)]
Clean up errno reporting and fix some errno-reporting bugs.

* callproc.c (Fcall_process):
* fileio.c (Fcopy_file, Finsert_file_contents, Fwrite_region):
* process.c (create_process, Fmake_network_process):
* unexaix.c (report_error):
* unexcoff.c (report_error):
Be more careful about reporting the errno of failed operations.
The code previously reported the wrong errno sometimes.
Also, prefer report_file_errno to setting errno + report_file_error.
(Fcall_process): Look at openp return value rather than at path,
as that's a bit faster and clearer when there's a numeric predicate.
* fileio.c (report_file_errno): New function, with most of the
old contents of report_file_error.
(report_file_error): Use it.
(Ffile_exists_p, Ffile_accessible_directory_p):
Set errno to 0 when it is junk.
* fileio.c (Faccess_file):
* image.c (x_create_bitmap_from_file):
Use faccessat rather than opening the file, to avoid the hassle of
having a file descriptor open.
* lisp.h (report_file_errno): New decl.
* lread.c (Flocate_file_internal): File descriptor 0 is valid, too.

11 years agoMinor EBADF fixes.
Paul Eggert [Fri, 12 Jul 2013 14:31:42 +0000 (07:31 -0700)]
Minor EBADF fixes.

* process.c (create_process, wait_reading_process_output) [AIX]:
Remove obsolete SIGHUP-related  code, as Emacs no longer disables
SIGHUP, so EBADF is no longer acceptable here (it wouldn't work in
a multithreaded environment anyway).
* sysdep.c (emacs_close): It's not dangerous to invoke emacs_close (-1).

11 years agolisp/desktop.el: Minor fixes.
Juanma Barranquero [Fri, 12 Jul 2013 11:21:01 +0000 (13:21 +0200)]
lisp/desktop.el: Minor fixes.
(desktop--v2s): Remove unused local variable.
(desktop-save-buffer): Make defvar-local; adjust docstring.
(desktop-auto-save-timeout, desktop-owner): Use ignore-errors.
(desktop-clear, desktop-save-buffer-p): Use string-match-p.

11 years agoAuto-commit of generated files.
Glenn Morris [Fri, 12 Jul 2013 10:17:37 +0000 (06:17 -0400)]
Auto-commit of generated files.

11 years agoRemove lisp/emacs-lisp/.gitignore
Andreas Schwab [Fri, 12 Jul 2013 09:33:10 +0000 (11:33 +0200)]
Remove lisp/emacs-lisp/.gitignore

11 years ago* emacs-lisp/map-ynp.el (map-y-or-n-p): Fix last change.
Andreas Schwab [Fri, 12 Jul 2013 09:33:09 +0000 (11:33 +0200)]
* emacs-lisp/map-ynp.el (map-y-or-n-p): Fix last change.

11 years ago* image.c (x_find_image_file): Don't close a remote file handle.
Andreas Schwab [Fri, 12 Jul 2013 09:02:30 +0000 (11:02 +0200)]
* image.c (x_find_image_file): Don't close a remote file handle.

11 years agoMinor followup to previous commit.
Eli Zaretskii [Fri, 12 Jul 2013 08:35:42 +0000 (11:35 +0300)]
Minor followup to previous commit.

 lisp/simple.el (next-line, previous-line): Document TRY-VSCROLL and ARG.

Fixes: debbugs:14842
11 years agoFix bug #14842 with doc strings of next-line and previous-line.
Eli Zaretskii [Fri, 12 Jul 2013 08:33:14 +0000 (11:33 +0300)]
Fix bug #14842 with doc strings of next-line and previous-line.

 lisp/simple.el (next-line, previous-line): Document TRY-VSCROLL.

11 years ago* admin/admin.el (manual-style-string): Use non-abbreviated url.
Glenn Morris [Fri, 12 Jul 2013 06:45:04 +0000 (23:45 -0700)]
* admin/admin.el (manual-style-string): Use non-abbreviated url.

11 years agoRemove some more reimplementations of cl-lib functions
Glenn Morris [Fri, 12 Jul 2013 03:54:57 +0000 (20:54 -0700)]
Remove some more reimplementations of cl-lib functions

* lisp/doc-view.el: Require cl-lib at runtime too.
(doc-view-remove-if): Remove.
(doc-view-search-next-match, doc-view-search-previous-match):
Use cl-remove-if.

* lisp/edmacro.el: Require cl-lib at runtime too.
(edmacro-format-keys, edmacro-parse-keys): Use cl-mismatch, cl-subseq.
(edmacro-mismatch, edmacro-subseq): Remove.

* lisp/filesets.el: Comments.

* lisp/shadowfile.el: Require cl-lib.
(shadow-remove-if): Remove.
(shadow-set-cluster, shadow-shadows-of-1, shadow-remove-from-todo):
Use cl-remove-if.

* lisp/wid-edit.el: Require cl-lib.
(widget-choose): Use cl-remove-if.
(widget-remove-if): Remove.

* lisp/progmodes/ebrowse.el: Require cl-lib at runtime too.
(ebrowse-delete-if-not): Remove.
(ebrowse-browser-buffer-list, ebrowse-member-buffer-list)
(ebrowse-tree-buffer-list, ebrowse-same-tree-member-buffer-list):
Use cl-delete-if-not.

11 years agoFix races with threads and file descriptors.
Paul Eggert [Fri, 12 Jul 2013 02:03:47 +0000 (19:03 -0700)]
Fix races with threads and file descriptors.

* configure.ac (PTY_TTY_NAME_SPRINTF): Use emacs_close, not close.
* src/callproc.c (Fcall_process_region):
* src/dired.c (open_directory):
* src/emacs.c (main, Fdaemon_initialized):
* src/image.c (x_find_image_file):
* src/inotify.c (Finotify_rm_watch):
* src/lread.c (Flocate_file_internal):
* src/process.c (Fnetwork_interface_list, Fnetwork_interface_info):
* src/term.c (term_mouse_moveto, init_tty):
* src/termcap.c (tgetent):
* src/unexaix.c, src/unexcoff.c (report_error, report_error_1, adjust_lnnoptrs)
* src/unexaix.c, src/unexcoff.c, src/unexcw.c, src/unexelf.c (unexec):
* src/unexhp9k800.c, src/unexmacosx.c (unexec):
* src/callproc.c (Fcall_process_region):
Use emacs_close, not close.
* src/sysdep.c (POSIX_CLOSE_RESTART, posix_close) [!POSIX_CLOSE_RESTART]:
New macro and function, which emulates the POSIX_CLOSE_RESTART macro
and posix_close function on current platforms (which all lack them).
(emacs_close): Use it.  This should fix the races on GNU/Linux and
on AIX and on future platforms that support POSIX_CLOSE_RESTART,
and it should avoid closing random victim file descriptors on
other platforms.

11 years agolisp/emacs-lisp/cl-macs.el: Fix typos in docstrings.
Juanma Barranquero [Fri, 12 Jul 2013 01:11:22 +0000 (03:11 +0200)]
lisp/emacs-lisp/cl-macs.el: Fix typos in docstrings.

11 years ago* ido.el (dired-do-copy, dired): Set 'ido property.
Leo Liu [Fri, 12 Jul 2013 01:01:53 +0000 (09:01 +0800)]
* ido.el (dired-do-copy, dired): Set 'ido property.

Fixes: debbugs:11954
11 years ago* inotify.c (uninitialized): Remove. All uses replaced by -1.
Paul Eggert [Thu, 11 Jul 2013 17:28:58 +0000 (10:28 -0700)]
* inotify.c (uninitialized): Remove.  All uses replaced by -1.

(Finotify_add_watch): Simplify, since -1 means uninitialized now.
Touch up doc a bit.

11 years agoChangeLog fix
Glenn Morris [Thu, 11 Jul 2013 17:27:27 +0000 (13:27 -0400)]
ChangeLog fix

11 years agoChangeLog fixes
Glenn Morris [Thu, 11 Jul 2013 17:18:48 +0000 (13:18 -0400)]
ChangeLog fixes

11 years agoRemove some reimplementations of cl-gensym
Glenn Morris [Thu, 11 Jul 2013 17:16:19 +0000 (13:16 -0400)]
Remove some reimplementations of cl-gensym

* lisp/thumbs.el: Require cl-lib at run-time too.
(thumbs-gensym-counter, thumbs-gensym):
Remove reimplementation of cl-gensym.
(thumbs-temp-file): Use cl-gensym.

* lisp/emacs-lisp/edebug.el: Require cl-lib at run-time too.
(edebug-gensym-index, edebug-gensym):
Remove reimplementation of cl-gensym.
(edebug-make-enter-wrapper, edebug-make-form-wrapper): Use cl-gensym.

11 years ago* admin/notes/changelogs: Explain "there is no need".
Glenn Morris [Thu, 11 Jul 2013 16:15:57 +0000 (09:15 -0700)]
* admin/notes/changelogs: Explain "there is no need".

11 years agoStop reimplementing a bunch of cl- functions in ert
Glenn Morris [Thu, 11 Jul 2013 16:13:38 +0000 (09:13 -0700)]
Stop reimplementing a bunch of cl- functions in ert

* lisp/emacs-lisp/ert.el: Require cl-lib at runtime too.
(ert--cl-do-remf, ert--remprop, ert--remove-if-not)
(ert--intersection, ert--set-difference, ert--set-difference-eq)
(ert--union, ert--gensym-counter, ert--gensym-counter)
(ert--coerce-to-vector, ert--remove*, ert--string-position)
(ert--mismatch, ert--subseq): Remove reimplementations of cl funcs.
(ert-make-test-unbound, ert--expand-should-1)
(ert--expand-should, ert--should-error-handle-error)
(should-error, ert--explain-equal-rec)
(ert--plist-difference-explanation, ert-select-tests)
(ert--make-stats, ert--remove-from-list, ert--string-first-line):
Use cl-lib functions rather than reimplementations.

* test/automated/ert-tests.el: Require cl-lib at runtime too.
(ert-test-special-operator-p): Use cl-gensym rather than ert-- version.
(ert-test-remprop, ert-test-remove-if-not, ert-test-remove*)
(ert-test-set-functions, ert-test-gensym)
(ert-test-coerce-to-vector, ert-test-string-position)
(ert-test-mismatch): Remove tests.

* test/automated/cl-lib.el: New, split from ert-tests.el.

11 years agoAdding :safe property to a defcustom does not merit a :version bump
Glenn Morris [Thu, 11 Jul 2013 16:07:00 +0000 (09:07 -0700)]
Adding :safe property to a defcustom does not merit a :version bump

11 years agoQuieten ruby-mode-tests.el compilation
Glenn Morris [Thu, 11 Jul 2013 16:04:56 +0000 (09:04 -0700)]
Quieten ruby-mode-tests.el compilation

* test/automated/ruby-mode-tests.el (ruby-deftest-move-to-block):
Goto point-min.
(works-on-do, zero-is-noop, ok-with-three, ok-with-minus-two)
(ruby-move-to-block-skips-percent-literal)
(ruby-move-to-block-skips-heredoc)
(ruby-move-to-block-moves-from-else-to-if)
(ruby-beginning-of-defun-does-not-fold-case)
(ruby-end-of-defun-skips-to-next-line-after-the-method):
Replace goto-line with forward-line/goto-char.
(ruby-move-to-block-does-not-fold-case): Remove unneeded end-of-buffer.

11 years agoSilence package-test.el compilation
Glenn Morris [Thu, 11 Jul 2013 16:01:26 +0000 (09:01 -0700)]
Silence package-test.el compilation

* test/automated/package-test.el (makeinfo-buffer): Autoload.
(compilation-in-progress, tar-parse-info, tar-header-name): Declare.
(package-test-install-texinfo): Don't require makeinfo.

11 years ago* test/automated/files.el: Stop "local variables" confusion.
Glenn Morris [Thu, 11 Jul 2013 16:00:05 +0000 (09:00 -0700)]
* test/automated/files.el: Stop "local variables" confusion.

11 years ago* automated/flymake-tests.el (flymake-tests): Remove unused group.
Glenn Morris [Thu, 11 Jul 2013 15:58:15 +0000 (08:58 -0700)]
* automated/flymake-tests.el (flymake-tests): Remove unused group.

11 years agoSilence icalendar-tests.el compilation
Glenn Morris [Thu, 11 Jul 2013 15:57:45 +0000 (08:57 -0700)]
Silence icalendar-tests.el compilation

* test/automated/icalendar-tests.el (icalendar-tests--do-test-cycle):
Use with-current-buffer.

11 years ago* undo-tests.el (undo-test-buffer-modified, undo-test-file-modified): New tests.
Glenn Morris [Thu, 11 Jul 2013 15:56:41 +0000 (08:56 -0700)]
* undo-tests.el (undo-test-buffer-modified, undo-test-file-modified): New tests.

11 years ago* net/tramp.el (tramp-methods): Extend docstring.
Michael Albinus [Thu, 11 Jul 2013 09:52:54 +0000 (11:52 +0200)]
* net/tramp.el (tramp-methods): Extend docstring.
(tramp-connection-timeout): New defcustom.
(tramp-error-with-buffer): Reset timestamp only when appropriate.
(with-tramp-progress-reporter): Simplify.
(tramp-process-actions): Improve messages.

* net/tramp-gvfs.el (tramp-gvfs-maybe-open-connection):
* net/tramp-sh.el (tramp-maybe-open-connection):
Use `tramp-connection-timeout'.
(tramp-methods) [su, sudo, ksu]: Add method specific timeouts.  (Bug#14808)

11 years ago* eval.c (backtrace_function, backtrace_args): Now EXTERNALLY_VISIBLE.
Paul Eggert [Thu, 11 Jul 2013 07:17:23 +0000 (00:17 -0700)]
* eval.c (backtrace_function, backtrace_args): Now EXTERNALLY_VISIBLE.

This is for .gdbinit xbacktrace.

11 years ago* ido.el (ido-read-file-name): Conform to the requirements of
Leo Liu [Thu, 11 Jul 2013 02:59:54 +0000 (10:59 +0800)]
* ido.el (ido-read-file-name): Conform to the requirements of
read-file-name.
(ido-read-directory-name): Conform to the requirements of
read-directory-name.

Fixes: debbugs:11861
11 years ago* sysdep.c, term.c, termcap.c, terminal.c: Integer-related minor fixes.
Paul Eggert [Thu, 11 Jul 2013 02:17:47 +0000 (19:17 -0700)]
* sysdep.c, term.c, termcap.c, terminal.c: Integer-related minor fixes.

* sysdep.c (emacs_get_tty): Return void, since nobody uses the value.
(emacs_set_tty): Now static.
* sysdep.c (emacs_set_tty, tabs_safe_p, emacs_close):
* term.c (tty_capable_p, tty_default_color_capabilities)
(get_tty_terminal, term_mouse_movement)
(handle_one_term_event, init_tty, maybe_fatal):
* termcap.c (tgetst1, struct termcap_buffer, valid_filename_p)
(tgetent, scan_file, name_match, compare_contin):
* terminal.c (get_terminal):
Use bool for boolean.
* sysdep.c (init_system_name): Don't overflow stack on huge hostname.
Prefer char to unsigned char if either will do.
* term.c (OUTPUT, turn_on_face): Omit unnecessary casts to int.
(tty_write_glyphs): Prefer int to unsigned.
(produce_glyphless_glyph): Remove 2nd (unused) int arg.
All callers changed.
* termcap.c (tprint, main) [TEST]: Remove non-working test.

11 years agolisp/subr.el (delay-warning): New function.
Juanma Barranquero [Thu, 11 Jul 2013 01:49:17 +0000 (03:49 +0200)]
lisp/subr.el (delay-warning): New function.

11 years agoPort to C89.
Paul Eggert [Wed, 10 Jul 2013 23:23:57 +0000 (16:23 -0700)]
Port to C89.

* lib-src/ebrowse.c (USAGE): Remove macro with too-long string literal ...
(usage_message): ... and replace it with this new static constant
containing multiple literals.  All uses changed.
* lib-src/emacsclient.c (print_help_and_exit):
Rewrite to avoid string literals longer than the C89 limits.
(start_daemon_and_retry_set_socket):
Rewrite to avoid non-constant array initializer.
* lib-src/make-docfile.c (enum global_type): Omit trailing comma.
* src/bytecode.c (BYTE_CODE_THREADED): Do not define if __STRICT_ANSI__.
(B__dummy__): New dummy symbol, to pacify C89.
* src/dbusbind.c (XD_DEBUG_MESSAGE): Omit debugging on C89 hosts, since
they can't grok varargs macros.
* src/dispnew.c (add_window_display_history)
(add_frame_display_history):
* src/print.c (print_object):
* src/xdisp.c (debug_method_add):
Use %p printf format only for void pointers.
* src/emacs.c (usage_message): New constant, replacing ...
(USAGE1, USAGE2, USAGE3): Remove; they were too long for C89.
(main): Adjust to usage reorg.
* src/fns.c (syms_of_fns):
* src/profiler.c (syms_of_profiler):
Don't use non-constant struct initializers.
* src/gnutls.h (gnutls_initstage_t):
* src/lisp.h (enum Lisp_Fwd_Type):
* src/lread.c (lisp_file_lexically_bound_p):
* src/xsettings.c (anonymous enum):
Remove trailing comma.
* src/xsettings.c (apply_xft_settings): Use %f, not %lf; %lf is a C99ism.
* src/lisp.h (ENUM_BF): Use unsigned if pedantic.
(DEFUN_FUNCTION_INIT): New macro, that falls back on a cast if pre-C99.
(DEFUN): Use it.
* src/regex.c (const_re_char): New type, to pacify strict C89.
All uses of 'const re_char' replaced to use it.
* src/regex.h (_Restrict_): Rename from __restrict, to avoid clash
with glibc when strict C89.  This change is imported from gnulib.
All uses changed.
(_Restrict_arr_): Rename from __restrict_arr, similarly.
* src/sysdep.c (time_from_jiffies) [!HAVE_LONG_LONG_INT]:
Omit GNU_LINUX implementation, since it requires long long.
* src/xterm.c (x_draw_underwave):
Do not assume the traditional order of struct's members.
(x_term_init): Rewrite to avoid the need for non-constant structure
initializers.

11 years agognus-start.el (gnus-clean-old-newsrc): Always remove 'unexist' marks if `gnus-newsrc...
David Engster [Wed, 10 Jul 2013 22:17:07 +0000 (22:17 +0000)]
gnus-start.el (gnus-clean-old-newsrc): Always remove 'unexist' marks if `gnus-newsrc-file-version' does not match `gnus-version'.  This fixes a bug in Emacs trunk where the 'unexist' marks were always removed at startup because "Gnus v5.13" was considered smaller than "Ma Gnus v0.03".

11 years agognus.el (gnus-summary-line-format): Docfix
Tassilo Horn [Wed, 10 Jul 2013 22:16:03 +0000 (22:16 +0000)]
gnus.el (gnus-summary-line-format): Docfix

11 years agoImprove scrolling when line-spacing != 0 and scroll-step = 1.
Eli Zaretskii [Wed, 10 Jul 2013 16:18:17 +0000 (19:18 +0300)]
Improve scrolling when line-spacing != 0 and scroll-step = 1.

 lisp/simple.el (default-line-height): New function.
 (line-move-partial, line-move): Use it instead of computing the
 line height inline.
 (line-move-partial): Always compute ROWH.  If the last line is
 partially-visible, but its text is completely visible, allow
 cursor to enter such a partially-visible line.

11 years agoSyntax cleanup, mostly replacing macros with functions.
Paul Eggert [Wed, 10 Jul 2013 16:11:09 +0000 (09:11 -0700)]
Syntax cleanup, mostly replacing macros with functions.

This removes the need for the syntax_temp hack.
* search.c: Include syntax.h after buffer.h, since syntax.h uses BVAR.
* syntax.c (SYNTAX_INLINE): New macro.
(SYNTAX_FLAGS_COMSTART_FIRST, SYNTAX_FLAGS_COMSTART_SECOND)
(SYNTAX_FLAGS_COMEND_FIRST, SYNTAX_FLAGS_COMEND_SECOND)
(SYNTAX_FLAGS_PREFIX, SYNTAX_FLAGS_COMMENT_STYLEB)
(SYNTAX_FLAGS_COMMENT_STYLEC, SYNTAX_FLAGS_COMMENT_STYLEC2)
(SYNTAX_FLAGS_COMMENT_NESTED, SYNTAX_FLAGS_COMMENT_STYLE)
(SYNTAX_COMEND_FIRST): Now functions, not macros.
(ST_COMMENT_STYLE, ST_STRING_STYLE, INTERVALS_AT_ONCE):
Now constants, not macros.
(syntax_temp) [!__GNUC__]: Remove.
(SYNTAX_PREFIX): Remove; all uses replaced by syntax_prefix_flag_p.
(syntax_prefix_flag_p): Move implementation of SYNTAX_PREFIX here.
(SET_RAW_SYNTAX_ENTRY, SET_RAW_SYNTAX_ENTRY_RANGE, SYNTAX_MATCH)
(SETUP_SYNTAX_TABLE, SETUP_SYNTAX_TABLE_FOR_OBJECT):
Move here from syntax.h; now functions, not macros.  Except for the
last function, these are static since only syntax.c uses them.
(syntax_multibyte): Rename from SYNTAX_WITH_MULTIBYTE_CHECK.
All uses changed.  Now a function, not a macro; use this fact
to simplify the code.
(scan_lists, scan_sexps_forward): Remove workarounds for ancient
compiler bugs; no longer relevant.
* syntax.h: Use INLINE_HEADER_BEGIN, INLINE_HEADER_END.
(SYNTAX_INLINE): New macro.
(struct gl_state_s, gl_state): Move earlier, so that it's in scope
for the new functions.  Use bool for boolean member.
(SYNTAX_ENTRY, SYNTAX, SYNTAX_WITH_FLAGS, SYNTAX_MATCH)
(SYNTAX_TABLE_BYTE_TO_CHAR, UPDATE_SYNTAX_TABLE_FORWARD)
(UPDATE_SYNTAX_TABLE_BACKWARD, UPDATE_SYNTAX_TABLE)
(SETUP_BUFFER_SYNTAX_TABLE):
Now extern inline functions, not macros.
(CURRENT_SYNTAX_TABLE, SYNTAX_ENTRY_INT):
Remove; all uses replaced by implementation.
(syntax_temp) [!__GNUC__]: Remove decl.
(SETUP_SYNTAX_TABLE_FOR_OBJECT): New decl.

11 years agoFix last patch.
Michael Albinus [Wed, 10 Jul 2013 15:18:39 +0000 (17:18 +0200)]
Fix last patch.

11 years agoImprove error messages. (Bug#14808)
Michael Albinus [Wed, 10 Jul 2013 14:58:26 +0000 (16:58 +0200)]
Improve error messages.  (Bug#14808)

* net/tramp.el (tramp-current-connection): New defvar, moved from
tramp-sh.el.
(tramp-message-show-progress-reporter-message): Removed, not
needed anymore.
(tramp-error-with-buffer): Show message in minibuffer.  Discard
input before waiting.  Reset connection timestamp.
(with-tramp-progress-reporter): Improve messages.
(tramp-process-actions): Use progress reporter.  Delete process in
case of error.  Improve messages.

* net/tramp-sh.el (tramp-barf-if-no-shell-prompt): Use
condition-case.  Call `tramp-error-with-buffer' with vector and buffer.
(tramp-current-connection): Removed.
(tramp-maybe-open-connection): The car of
`tramp-current-connection' are the first 3 slots of the vector.

11 years ago* progmodes/cfengine.el: Do not indent inside continued strings.
Ted Zlatanov [Wed, 10 Jul 2013 14:34:13 +0000 (10:34 -0400)]
* progmodes/cfengine.el: Do not indent inside continued strings.

11 years agoAdd comment.
Michael Albinus [Wed, 10 Jul 2013 14:07:17 +0000 (16:07 +0200)]
Add comment.

11 years ago* emacs.c (main): Fix syntax error.
Jan Djärv [Wed, 10 Jul 2013 11:27:15 +0000 (13:27 +0200)]
* emacs.c (main): Fix syntax error.

11 years agoAuto-commit of generated files.
Glenn Morris [Wed, 10 Jul 2013 10:17:38 +0000 (06:17 -0400)]
Auto-commit of generated files.

11 years ago* Makefile.in (removenullpaths): Remove adjacent null paths.
Paul Eggert [Wed, 10 Jul 2013 06:41:37 +0000 (23:41 -0700)]
* Makefile.in (removenullpaths): Remove adjacent null paths.

Fixes: debbugs:14835
11 years agoTimestamp fixes for undo.
Paul Eggert [Wed, 10 Jul 2013 06:26:23 +0000 (23:26 -0700)]
Timestamp fixes for undo.

* doc/lispref/text.texi (Undo):
Document (t . 0) and (t . -1) in buffer-undo-list.
* etc/NEWS: Changes to visited-file-modtime, set-visited-file-modtime.
* lisp/files.el (clear-visited-file-modtime): Move here from fileio.c.
* src/atimer.c (schedule_atimer):
* src/fileio.c (Ffile_newer_than_file_p):
Minor cleanup: use EMACS_TIME_LT so that we can remove EMACS_TIME_GT.
* src/buffer.c (buffer-undo-list): Document (t . 0) and (t . -1).
* src/fileio.c (Fclear_visited_file_modtime): Move to lisp/files.el.
(syms_of_fileio): Remove Sclear_visited_file_name.
(Fvisited_file_modtime): Return -1, not (-1 ...), when the visited
file doesn't exist; this avoids an ambiguity with negative timestamps.
(Fset_visited_file_modtime): Accept -1 and 0 as time-list arg.
* src/systime.h (make_emacs_time, invalid_emacs_time):
Don't assume struct timespec layout; POSIX doesn't guarantee it.
(EMACS_TIME_NE, EMACS_TIME_GT, EMACS_TIME_GE): Remove.
* src/undo.c (record_first_change): Push (visited-file-modtime) onto
undo list rather than reimplementing it by hand, incorrectly.

Fixes: debbugs:14824
11 years ago* files.el (require-final-newline): Allow safe local value.
Leo Liu [Wed, 10 Jul 2013 03:10:27 +0000 (11:10 +0800)]
* files.el (require-final-newline): Allow safe local value.

Fixes: debbugs:14834
11 years agoAvoid nexted functions in AC_LANG_PROGRAM test for Windows headers.
Peter Rosin [Tue, 9 Jul 2013 18:06:25 +0000 (21:06 +0300)]
Avoid nexted functions in AC_LANG_PROGRAM test for Windows headers.

 configure.ac (HAVE_W32): Avoid nested functions (the second
 argument of AC_LANG_PROGRAM is already expanded inside a
 function).

Fixes: debbugs:14830
11 years agoPort recent close-on-exec changes to Cygwin.
Paul Eggert [Tue, 9 Jul 2013 17:16:21 +0000 (10:16 -0700)]
Port recent close-on-exec changes to Cygwin.

* lib/binary-io.c, lib/binary-io.h: New files.
Merge from gnulib, incorporating:
2013-07-09 accept4, dup3, pipe2: port to Cygwin
* lib/pipe2.c: Update from gnulib, as part of this merge.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.

Fixes: debbugs:14821
11 years ago* src/sheap.c (STATIC_HEAP_SIZE) [__x86_64__]: Increase to 18MB.
Ken Brown [Tue, 9 Jul 2013 13:56:47 +0000 (09:56 -0400)]
* src/sheap.c (STATIC_HEAP_SIZE) [__x86_64__]: Increase to 18MB.

11 years agoAuto-commit of generated files.
Glenn Morris [Tue, 9 Jul 2013 10:17:37 +0000 (06:17 -0400)]
Auto-commit of generated files.

11 years agosrc/makefile.w32-in ($(BLD)/emacs.$(O), $(BLD)/sysdep.$(O)): Update.
Juanma Barranquero [Tue, 9 Jul 2013 09:53:00 +0000 (11:53 +0200)]
src/makefile.w32-in ($(BLD)/emacs.$(O), $(BLD)/sysdep.$(O)): Update.

11 years ago* automated/file-notify-tests.el (file-notify-test00-availability):
Michael Albinus [Tue, 9 Jul 2013 07:52:25 +0000 (09:52 +0200)]
* automated/file-notify-tests.el (file-notify-test00-availability):
Set :expected-result.
(file-notify-test01-add-watch, file-notify-test01-add-watch-remote)
(file-notify-test02-events, file-notify-test02-events-remote)
(file-notify-test03-autorevert, file-notify-test03-autorevert-remote):
Skip when `file-notify-support' is nil.  (Bug#14823)

11 years ago* automated/inotify-test.el (inotify-add-watch, inotify-rm-watch): Declare.
Glenn Morris [Tue, 9 Jul 2013 07:43:12 +0000 (00:43 -0700)]
* automated/inotify-test.el (inotify-add-watch, inotify-rm-watch): Declare.
(inotify-file-watch-simple): Silence compiler.

11 years ago* test/automated/python-tests.el (python-indent-block-enders):
Glenn Morris [Tue, 9 Jul 2013 07:35:26 +0000 (00:35 -0700)]
* test/automated/python-tests.el (python-indent-block-enders):
Make it actually test something.

11 years agoChangeLog fix
Glenn Morris [Tue, 9 Jul 2013 07:14:39 +0000 (00:14 -0700)]
ChangeLog fix

11 years agoExplictly require ert in some test/automated/*.el files
Glenn Morris [Tue, 9 Jul 2013 07:11:50 +0000 (00:11 -0700)]
Explictly require ert in some test/automated/*.el files

* automated/add-log-tests.el, automated/advice-tests.el:
* automated/imenu-test.el, automated/python-tests.el:
* automated/ruby-mode-tests.el, automated/xml-parse-tests.el:
Explictly require ert.

11 years agoHandle errno and exit status a bit more carefully.
Paul Eggert [Tue, 9 Jul 2013 07:04:48 +0000 (00:04 -0700)]
Handle errno and exit status a bit more carefully.

* lib/ignore-value.h: Remove this gnulib-imported file.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
* admin/merge-gnulib (GNULIB_MODULES): Remove ignore-value.
* src/callproc.c (child_setup) [!DOS_NT]: Don't try to stuff an error
number into an exit status.  Instead, use EXIT_CANCELED.
(child_setup) [!MSDOS]: Avoid possible deadlock with vfork.
* src/callproc.c (relocate_fd):
* src/emacs.c (close_output_streams, main):
* src/process.c (create_process):
* src/sysdep.c (sys_subshell) [!DOS_NT || !WINDOWSNT]:
Use emacs_perror for simplicity.
* src/callproc.c (relocate_fd, main):
* src/sysdep.c (sys_subshell):
Exit with EXIT_CANCELED etc., not 1, when exec setup fails.
(shut_down_emacs): Use emacs_write, not write.
* src/emacs.c, src/sysdep.c: Don't include <ignore-value.h>.
* src/fileio.c (Fcopy_file, e_write):
* src/nsterm.m (ns_select):
* src/process.c (send_process):
* src/sound.c (vox_write):
Use emacs_write_sig, not emacs_write.
* src/lisp.h (emacs_write_sig, emacs_perror): New decls.
* src/process.h (EXIT_CANCELED), EXIT_CANNOT_INVOKE, EXIT_ENOENT):
New constants.
* src/sysdep.c (emacs_backtrace): Use emacs_write, not ignore_value
of write.
(emacs_full_write): New function.
(emacs_write): Rewrite to use it.
(emacswrite_sig, emacs_perror): New functions.
* src/xrdb.c (fatal): Don't invoke perror, since errno might be garbage.