]> git.eshelyaron.com Git - emacs.git/log
emacs.git
7 years agoImprove previous cperl-mode change
Glenn Morris [Sun, 11 Dec 2016 03:37:59 +0000 (19:37 -0800)]
Improve previous cperl-mode change

* lisp/progmodes/cperl-mode.el (cperl-mode-abbrev-table):
Improve previous change.

7 years agoMark default cperl abbrevs as system ones
Glenn Morris [Sun, 11 Dec 2016 03:26:25 +0000 (19:26 -0800)]
Mark default cperl abbrevs as system ones

* lisp/progmodes/cperl-mode.el (cperl-mode):
Mark our abbrevs as system ones.  (Bug#10934)

7 years agoRevert earlier Ffset change
Glenn Morris [Sun, 11 Dec 2016 03:18:24 +0000 (19:18 -0800)]
Revert earlier Ffset change

* src/data.c (Ffset): Allow nil again, since it caused
eager macro-expansion failures.

7 years agoTweaks for message bogus address detection
Glenn Morris [Sun, 11 Dec 2016 03:03:28 +0000 (19:03 -0800)]
Tweaks for message bogus address detection

* lisp/gnus/message.el (message-bogus-recipient-p):
Do not require "@", since some mailers deliver to local addresses
without one.  (Bug#23054)
Move "@.*@" from here...
(message-bogus-addresses): ...to here, so it can be customized.

7 years agoDo not allow nil to be defined as a function
Glenn Morris [Sun, 11 Dec 2016 02:58:24 +0000 (18:58 -0800)]
Do not allow nil to be defined as a function

* lisp/emacs-lisp/byte-run.el (defun):
* src/data.c (Ffset): Do not allow "nil".  (Bug#25110)

7 years agoAdd some sanity checking of defun arglist
Nicolas Richard [Sun, 11 Dec 2016 01:48:10 +0000 (17:48 -0800)]
Add some sanity checking of defun arglist

* lisp/emacs-lisp/byte-run.el (defun):
Check for malformed argument lists.  (Bug#15715)

7 years agoMinor shell-mode fix for zsh
Matt Armstrong [Sun, 11 Dec 2016 01:29:51 +0000 (17:29 -0800)]
Minor shell-mode fix for zsh

* lisp/shell.el (shell-mode): Prevent shell-dirstack-query
becoming confused by zsh abbreviations.  (Bug#24632)

Copyright-paperwork-exempt: yes

7 years ago* Makefile.in (install-etc): Don't prepend $(DESTDIR) to commands in
Andreas Schwab [Sat, 10 Dec 2016 20:13:06 +0000 (21:13 +0100)]
* Makefile.in (install-etc): Don't prepend $(DESTDIR) to commands in
system unit file.

7 years ago; Fix copyright years in new files
Glenn Morris [Sat, 10 Dec 2016 18:19:06 +0000 (10:19 -0800)]
; Fix copyright years in new files

7 years ago; Update file name in comment
Philipp Stephani [Sat, 10 Dec 2016 17:23:15 +0000 (18:23 +0100)]
; Update file name in comment

7 years agoSupport concurrency in Emacs Lisp
Eli Zaretskii [Sat, 10 Dec 2016 16:54:43 +0000 (18:54 +0200)]
Support concurrency in Emacs Lisp

Merge branch 'test-concurrency'

* src/thread.c:
* src/thread.h:
* src/systhread.c:
* src/systhread.h: New files.
* src/xgselect.c (xg_select): Avoid using SAFE_NALLOCA and use
xnmalloc unconditionally.
* src/window.c (struct save_window_data): Rename current_buffer to
f_current_buffer.
* src/w32proc.c (sys_select): Change the function signature to
closer fit 'pselect' on Posix hosts.
* src/search.c:
* src/regex.h: Convert some globals to macros that reference
thread-specific values.
* src/process.c (pset_thread, add_non_keyboard_read_fd)
(add_process_read_fd, add_non_blocking_write_fd)
(recompute_input_desc, compute_input_wait_mask)
(compute_non_process_wait_mask, compute_non_keyboard_wait_mask)
(compute_write_mask, clear_waiting_thread_info)
(update_processes_for_thread_death, Fset_process_thread)
(Fprocess_thread): New functions.
(enum fd_bits): New enumeration.
(fd_callback_data): Add 'thread' and 'waiting_thread', rename
'condition' to 'flags'.
(set_process_filter_masks, create_process, create_pty)
(Fmake_serial_process, finish_after_tls_connection)
(connect_network_socket, deactivate_process)
(server_accept_connection, wait_reading_process_output)
(Fcontinue_process, Fstop_process, keyboard_bit_set)
(add_timer_wait_descriptor, add_keyboard_wait_descriptor)
(delete_keyboard_wait_descriptor): Use the new functions instead
of manipulating fd flags and masks directly.
(syms_of_process): Defsubr the new primitives.
* src/print.c (print_object): Print threads, mutexes, and
conditional variables.
* src/lisp.h (enum pvec_type): New values PVEC_THREAD, PVEC_MUTEX,
and PVEC_CONDVAR.
(XTHREAD, XMUTEX, XCONDVAR, THREADP, MUTEXP, CONDVARP)
(CHECK_THREAD, CHECK_MUTEX, CHECK_CONDVAR): New inline functions.
(XSETTHREAD, XSETMUTEX, XSETCONDVAR): New macros.
(struct handler): Add back byte_stack.  Rename lisp_eval_depth to
f_lisp_eval_depth.
* src/eval.c (specpdl_kind, specpdl_arg, do_specbind)
(rebind_for_thread_switch, do_one_unbind)
(unbind_for_thread_switch): New functions.
(init_eval): 'handlerlist' is not malloc'ed.
(specbind): Call do_specbind.
(unbind_to): Call do_one_unbind.
(mark_specpdl): Accept 2 arguments.
(mark_specpdl): Mark the saved value in a let-binding.
* src/emacs.c (main): Call init_threads_once, init_threads, and
syms_of_threads.
* src/data.c (Ftype_of): Support thread, mutex, and condvar
objects.
(Fthreadp, Fmutexp, Fcondition_variable_p): New functions.
(syms_of_data): DEFSYM and defsubr new symbols and primitives.
* src/bytecode.c (struct byte_stack, FETCH, CHECK_RANGE)
(BYTE_CODE_QUIT): Add back.
(exec_byte_code): Add back byte stack manipulation.
* src/alloc.c (cleanup_vector): Handle threads, mutexes, and
conditional variables.
(mark_stack): Now extern; accept additional argument 'bottom'.
(flush_stack_call_func): New function.
(garbage_collect_1): Call mark_threads and unmark_threads.  Don't
mark handlers.
* src/.gdbinit (xbytecode): Add back.

* test/src/thread-tests.el: New tests.
* test/src/data-tests.el (binding-test-manual)
(binding-test-setq-default, binding-test-makunbound)
(binding-test-defvar-bool, binding-test-defvar-int)
(binding-test-set-constant-t, binding-test-set-constant-nil)
(binding-test-set-constant-keyword)
(binding-test-set-constant-nil): New tests.

* doc/lispref/processes.texi (Processes and Threads): New
subsection.
* doc/lispref/threads.texi: New file
* doc/lispref/elisp.texi (Top): Include it.
* doc/lispref/objects.texi (Thread Type, Mutex Type)
(Condition Variable Type): New subsections.
(Type Predicates): Add thread-related predicates.
* doc/lispref/objects.texi (Editing Types):
* doc/lispref/elisp.texi (Top): Update higher-level menus.

* etc/NEWS: Mention concurrency features.

7 years agoFix error messages in thread.c
Eli Zaretskii [Sat, 10 Dec 2016 09:42:48 +0000 (11:42 +0200)]
Fix error messages in thread.c

* src/thread.c (lisp_mutex_unlock, Fcondition_wait)
(Fcondition_notify, Fthread_join): Fix error messages.

7 years agoImprove doc strings in thread.c
Eli Zaretskii [Sat, 10 Dec 2016 09:31:11 +0000 (11:31 +0200)]
Improve doc strings in thread.c

* src/thread.c (Fmake_condition_variable, Fcondition_wait)
(Fcondition_notify, Fcondition_mutex, Fcondition_name, Fmake_thread)
(Fthread_join, Fall_threads): Doc fixes.

7 years agoFix building with check-lisp-object-type
Eli Zaretskii [Sat, 10 Dec 2016 09:06:23 +0000 (11:06 +0200)]
Fix building with check-lisp-object-type

* src/thread.c (mark_one_thread): Use NILP to compare with
m_saved_last_thing_searched, which is a Lisp object.  Reported by
Andreas Politz <politza@hochschule-trier.de>.

7 years agoDocumentation and commentary improvements
Eli Zaretskii [Sat, 10 Dec 2016 08:49:39 +0000 (10:49 +0200)]
Documentation and commentary improvements

* src/lisp.h:
* src/regex.c:
* src/xgselect.c (xg_select): Improve commentary and formatting.

* doc/lispref/objects.texi (Thread Type, Mutex Type)
(Condition Variable Type): New subsections.
(Type Predicates): Add thread-related predicates.
* doc/lispref/objects.texi (Editing Types):
* doc/lispref/elisp.texi (Top): Update higher-level menus.

7 years agoFix further problems with quoted file names in Tramp
Michael Albinus [Fri, 9 Dec 2016 18:54:20 +0000 (19:54 +0100)]
Fix further problems with quoted file names in Tramp

* lisp/net/tramp.el (tramp-quoted-name-p, tramp-quote-name)
(tramp-unquote-name): Move defsubst ...
* lisp/net/tramp-compat.el (tramp-compat-file-name-quoted-p)
(tramp-compat-file-name-quote)
(tramp-compat-file-name-unquote): ... here. Adapt callees.

* lisp/net/tramp-cache.el (tramp-flush-file-property)
(tramp-flush-directory-property):
* lisp/net/tramp-gvfs.el (tramp-gvfs-url-file-name):
* lisp/net/tramp-sh.el (tramp-make-copy-program-file-name):
* lisp/net/tramp-smb.el (tramp-smb-handle-copy-file)
(tramp-smb-handle-substitute-in-file-name)
(tramp-smb-get-share, tramp-smb-get-localname): Handle quoted files.

7 years ago*src/sysdep.c: Fix a comment.
Eli Zaretskii [Fri, 9 Dec 2016 17:04:36 +0000 (19:04 +0200)]
*src/sysdep.c: Fix a comment.

7 years agoFix compilation error on Fedora 24
Eli Zaretskii [Fri, 9 Dec 2016 16:51:59 +0000 (18:51 +0200)]
Fix compilation error on Fedora 24

* src/sysdep.c [HAVE_H_ERRNO]: Remove declaration of h_errno.
Reported by Paul Eggert <eggert@cs.ucla.edu>.

7 years agoFix compilation warnings due to prototype of thread_select
Eli Zaretskii [Fri, 9 Dec 2016 16:23:04 +0000 (18:23 +0200)]
Fix compilation warnings due to prototype of thread_select

* src/thread.h <int select_func>: Make the 5th and 6th arguments
be 'const'.
* src/process.c [WINDOWSNT]:
* src/w32proc.c: Make the 5th and 6th argument to sys_select be
'const'.

7 years agoFix compilation on Debian GNU/Linux
Eli Zaretskii [Fri, 9 Dec 2016 16:04:27 +0000 (18:04 +0200)]
Fix compilation on Debian GNU/Linux

* src/thread.h: Include sys/types.h, for ssize_t that regex.h
uses.  Reported by Robert Marshall <robert.marshall@codethink.co.uk>.

7 years agoFix subtle errors with let-binding of localized variables
Eli Zaretskii [Fri, 9 Dec 2016 14:03:08 +0000 (16:03 +0200)]
Fix subtle errors with let-binding of localized variables

* src/eval.c (do_specbind): Don't require a "symbol" that is
actually a cons cell, in order to call set-default, as there are
no longer such bindings.  This makes do_specbind work like the
pre-concurrency implementation in specbind for bindings of
forwarded symbols.  Use specpdl_kind to access the type of the
binding.
(specpdl_kind): New function.

7 years agoDocument file-name-quote, file-name-unquote and file-name-quoted-p
Michael Albinus [Fri, 9 Dec 2016 09:03:05 +0000 (10:03 +0100)]
Document file-name-quote, file-name-unquote and file-name-quoted-p

* doc/lispref/files.texi (File Name Expansion):
* etc/NEWS: Mention file-name-quote, file-name-unquote and
file-name-quoted-p.

* lisp/files.el (file-name-non-special): Revert using
file-name-quote, file-name-unquote and file-name-quoted-p.

7 years agoFix bad quoting of python-shell-interpreter
Noam Postavsky [Fri, 9 Dec 2016 05:14:48 +0000 (00:14 -0500)]
Fix bad quoting of python-shell-interpreter

`python-shell-calculate-command' was using `shell-quote-argument' as if
it was generating a shell command, but its callers don't pass the result
to a shell, and they expect to parse it with `split-string-and-unquote'.
This caused problems depending on the flavor of shell quoting in
effect (Bug#25025).

* lisp/progmodes/python.el (python-shell-calculate-command): Use
`combine-and-quote-strings' to quote the interpreter, so that it can be
parsed by `python-shell-make-comint' successfully using
`split-string-and-unquote'.

7 years ago* src/lisp.h (struct terminal): Remove unnecessary forward decl.
Paul Eggert [Fri, 9 Dec 2016 02:17:15 +0000 (18:17 -0800)]
* src/lisp.h (struct terminal): Remove unnecessary forward decl.

7 years agoMake read1 more reentrant
Paul Eggert [Thu, 8 Dec 2016 19:32:48 +0000 (11:32 -0800)]
Make read1 more reentrant

This is needed if ‘read’ is called soon after startup, before the
Unicode tables have been set up, and it reads a \N escape and
needs to look up a value the Unicode tables, a lookup that in turn
calls read1 recursively.  Although this change doesn’t make ‘read’
fully reentrant, it’s good enough to handle this case.
* src/lread.c (read_buffer_size, read_buffer): Remove static vars.
(grow_read_buffer): Revamp to use locals, not statics, and to
record memory allocation un the specpdl.  All callers changed.
(read1): Start with a stack-based buffer, and use the heap
only if the stack buffer is too small.  Use unbind_to to
free any heap buffer allocated.  Use bool for boolean.
Redo symbol loop so that only one call to grow_read_buffer
is needed.
(init_obarray): Remove no-longer-needed initialization.

7 years agoFix compilation warnings
Eli Zaretskii [Thu, 8 Dec 2016 18:47:27 +0000 (20:47 +0200)]
Fix compilation warnings

* src/thread.c (Fmake_thread): Call emacs_abort, to avoid
compilation warning.

7 years agoFix unlikely substitute-command-keys memory leak
Paul Eggert [Thu, 8 Dec 2016 18:43:11 +0000 (10:43 -0800)]
Fix unlikely substitute-command-keys memory leak

* src/doc.c (Fsubstitute_command_keys):
Free buffer when unwinding.

7 years ago; Fix last patch
Michael Albinus [Thu, 8 Dec 2016 17:33:26 +0000 (18:33 +0100)]
; Fix last patch

7 years agoAdd file-name-quoted-p, file-name-quote, file-name-unquote
Michael Albinus [Thu, 8 Dec 2016 17:00:10 +0000 (18:00 +0100)]
Add file-name-quoted-p, file-name-quote, file-name-unquote

* lisp/files.el (file-name-quoted-p, file-name-quote)
(file-name-unquote): New defsubst.
(find-file--read-only, find-file-noselect)
(file-name-non-special): Use them.

7 years agoAdd a NEWS entry.
Eli Zaretskii [Thu, 8 Dec 2016 16:35:40 +0000 (18:35 +0200)]
Add a NEWS entry.

7 years agoMinor fix for symbol-file
Glenn Morris [Thu, 8 Dec 2016 07:18:36 +0000 (23:18 -0800)]
Minor fix for symbol-file

* lisp/subr.el (symbol-file): Avoid false matches with "require"
elements in load-history.  (Bug#25109)

7 years agoFix Bug#24962
Tino Calancha [Thu, 8 Dec 2016 04:46:25 +0000 (13:46 +0900)]
Fix Bug#24962

* lisp/buff-menu.el (list-buffers--refresh):
List buffers with name starting with " " if they visit a file.
* test/lisp/buff-menu-tests.el (buff-menu-24962):
Update test result as pass.

7 years agoediff-fixup-patch-map: Improve prompt
Tino Calancha [Thu, 8 Dec 2016 02:32:02 +0000 (11:32 +0900)]
ediff-fixup-patch-map: Improve prompt

* lisp/vc/ediff-ptch.el (ediff-fixup-patch-map):
Make clear in the prompt when we are applying a multi patch.

7 years agoRetain message logging in map-y-or-n-p
Glenn Morris [Thu, 8 Dec 2016 01:25:36 +0000 (20:25 -0500)]
Retain message logging in map-y-or-n-p

* lisp/emacs-lisp/map-ynp.el (map-y-or-n-p):
Stop disabling logging to Messages buffer.  (Bug#13326)

7 years agoDoc fix for recent change
Glenn Morris [Thu, 8 Dec 2016 01:10:54 +0000 (20:10 -0500)]
Doc fix for recent change

* lisp/simple.el (region-modifiable-p): Doc fix.

7 years agoQuieten make-dist default operation
Glenn Morris [Thu, 8 Dec 2016 00:59:14 +0000 (19:59 -0500)]
Quieten make-dist default operation

* make-dist: Add --verbose option.  Default to quieter operation.

7 years agoFix regression introduced by commit 7b1e97f
Tino Calancha [Wed, 7 Dec 2016 22:27:36 +0000 (07:27 +0900)]
Fix regression introduced by commit 7b1e97f

* lisp/ibuf-ext.el (ibuffer-decompose-filter): Use cdr instead
of cadr; required after commit 20f5a5b.

7 years agoPut post-25 ChangeLog entries into ChangeLog.3
Paul Eggert [Wed, 7 Dec 2016 20:53:02 +0000 (12:53 -0800)]
Put post-25 ChangeLog entries into ChangeLog.3

* ChangeLog.2: Copy from emacs-25 branch.
* ChangeLog.3: New file, with changes only in master.
* Makefile.in (CHANGELOG_HISTORY_INDEX_MAX): Bump from 2 to 3.

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:43:16 +0000 (12:43 -0800)]
Merge from origin/emacs-25

eeecac7 Fix minor quoting problems in doc strings

7 years ago; Merge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:41:06 +0000 (12:41 -0800)]
; Merge from origin/emacs-25

The following commit was skipped:

da71c89 * lisp/emacs-lisp/easy-mmode.el (define-minor-mode): Fix docs...

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:41:05 +0000 (12:41 -0800)]
Merge from origin/emacs-25

35ce3fb Don't assume window-point and point are the same

7 years ago; Merge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:41:05 +0000 (12:41 -0800)]
; Merge from origin/emacs-25

The following commit was skipped:

a3487a8 Fix bug#25087

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:41:05 +0000 (12:41 -0800)]
Merge from origin/emacs-25

ba2847f ; * lisp/vc/ediff-util.el (ediff-janitor): Fix last change.  ...
8b43f97 * lisp/vc/ediff-util.el (ediff-janitor): Doc fix.  (Bug#25046)
c20035c ; * doc/emacs/programs.texi (Man Page): Fix last change.
93d8346 Improve indexing of 'man'

7 years ago; Merge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:41:05 +0000 (12:41 -0800)]
; Merge from origin/emacs-25

The following commits were skipped:

c491989 Port to Sun C 5.14
95eb641 Fix mail-combine-fields

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:41:04 +0000 (12:41 -0800)]
Merge from origin/emacs-25

d31298d Fix documentation of `window-combination-resize'
2086f4c Typo fixes in elisp manual

7 years ago; Merge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:41:04 +0000 (12:41 -0800)]
; Merge from origin/emacs-25

The following commit was skipped:

f6da597 ; Revert "Guard terminal par. in XTerm mouse mode"

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:40:43 +0000 (12:40 -0800)]
Merge from origin/emacs-25

3980903 ; Update ChangeLog.2, etc/AUTHORS and ldef-boot.el for Emacs ...
5878abf Fix 'expand-file-name' during startup on MS-Windows

7 years ago; Merge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:39:08 +0000 (12:39 -0800)]
; Merge from origin/emacs-25

The following commit was skipped:

4606529 ; ChangeLog.2 update

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:39:08 +0000 (12:39 -0800)]
Merge from origin/emacs-25

9a857b9 * admin/authors.el (authors-renamed-files-alist): Addition.
6d27423 Tweak refcard note about documentation location
e46a134 Improve treatment of Fortran's "class is"

7 years ago; Merge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:39:08 +0000 (12:39 -0800)]
; Merge from origin/emacs-25

The following commits were skipped:

3674317 Bump Emacs version to 25.1.90
938e316 ; Revert "Bump Emacs version"
596289b Bump Emacs version
dcfe4d1 ; ChangeLog.2 update

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:39:07 +0000 (12:39 -0800)]
Merge from origin/emacs-25

93c0f51 Handle TeX comments when making new paragraph
e0884f1 Restore keystroke echo in 'C-q'
a6213ce Improve documentation of 'current-word'
0828126 Fix a typo in an Eshell defcustom
2e361c7 Minor copyedits of electric-pair-mode
7499ee8 ; Minor copyedit in the Emacs manual
45b652b Fix documentation of 'invocation-directory'
7f43d7c * admin/authors.el (authors-aliases): Add an entry.
ba48880 ; Fix pl-refcard.tex

7 years ago; Merge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:39:07 +0000 (12:39 -0800)]
; Merge from origin/emacs-25

The following commit was skipped:

d4e1549 Guard terminal parameter in XTerm mouse mode

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:39:06 +0000 (12:39 -0800)]
Merge from origin/emacs-25

7287e96 ; * src/lread.c (openp): Correct an inaccuracy in commentary.

7 years ago; Merge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:39:06 +0000 (12:39 -0800)]
; Merge from origin/emacs-25

The following commit was skipped:

3f2b497 * etc/AUTHORS: Regenerate the AUTHORS file

7 years agoMerge from origin/emacs-25
Paul Eggert [Wed, 7 Dec 2016 20:36:38 +0000 (12:36 -0800)]
Merge from origin/emacs-25

3d63b48 Update ChangeLog files and authors.el
9d30264 Fix menu bindings of Dired 'A' and 'Q' commands
a725592 Avoid errors in shr-pixel-column due to dedicated windows
3138598 Update format-time-string documentation

7 years agodelete-trailing-whitespace: handle read-only text in buffer
Sam Steingold [Wed, 7 Dec 2016 20:06:08 +0000 (15:06 -0500)]
delete-trailing-whitespace: handle read-only text in buffer

* lisp/simple.el (region-modifiable-p): New function.
(delete-trailing-whitespace): Us it to avoid trying to delete read-only text.

7 years agoFix minor quoting problems in doc strings
Paul Eggert [Wed, 7 Dec 2016 19:29:54 +0000 (11:29 -0800)]
Fix minor quoting problems in doc strings

7 years agoFix network streams.
Eli Zaretskii [Wed, 7 Dec 2016 19:01:40 +0000 (21:01 +0200)]
Fix network streams.

The original code messed up flags in fd_callback_data[], and also
didn't call add_process_read_fd for process-related file descriptors.

7 years agoFix --enable-gcc-warnings --with-ns on Fedora
Paul Eggert [Wed, 7 Dec 2016 18:29:57 +0000 (10:29 -0800)]
Fix --enable-gcc-warnings --with-ns on Fedora

* src/Makefile.in (NON_OBJC_CFLAGS): New macro.
(ALL_OBJC_CFLAGS): Use it.
(EMACS_CFLAGS): New macro, with most of the old ALL_CFLAGS.
(ALL_CFLAGS, ALL_OBJC_FLAGS): Use it.

7 years agoMinimize spurious diffs from master.
Eli Zaretskii [Wed, 7 Dec 2016 17:08:24 +0000 (19:08 +0200)]
Minimize spurious diffs from master.

7 years agoFix problems in quoting Tramp file names
Michael Albinus [Wed, 7 Dec 2016 16:16:57 +0000 (17:16 +0100)]
Fix problems in quoting Tramp file names

* lisp/net/tramp.el (tramp-get-remote-tmpdir): Add also hop to result.
(tramp-unquote-shell-quote-argument): New defun.
(tramp-shell-quote-argument):
* lisp/net/tramp-sh.el (tramp-do-copy-or-rename-file-out-of-band)
(tramp-make-copy-program-file-name):
* lisp/net/tramp-smb.el (tramp-smb-handle-copy-directory)
(tramp-smb-handle-file-acl, tramp-smb-handle-set-file-acl)
(tramp-smb-shell-quote-argument): Use it.

7 years ago; Fix previous commit
Mark Oteiza [Wed, 7 Dec 2016 14:43:27 +0000 (09:43 -0500)]
; Fix previous commit

7 years agoibuffer-map-deletion-lines: Re-included it
Tino Calancha [Wed, 7 Dec 2016 14:02:26 +0000 (23:02 +0900)]
ibuffer-map-deletion-lines: Re-included it

It was deleted in previous commit, but it's referenced
by the macro 'define-ibuffer-op'.
* lisp/ibuffer.el (ibuffer-map-deletion-lines): Reinclude it.

7 years agoibuffer-unmark-all: simplify code
Tino Calancha [Wed, 7 Dec 2016 13:25:11 +0000 (22:25 +0900)]
ibuffer-unmark-all: simplify code

* lisp/ibuffer.el (ibuffer-map-deletion-lines): Delete it.
(ibuffer-unmark-all): Simplify code.

7 years agodefine-ibuffer-filter: Discard wrong filters
Tino Calancha [Wed, 7 Dec 2016 13:02:54 +0000 (22:02 +0900)]
define-ibuffer-filter: Discard wrong filters

* lisp/ibuf-macs.el (define-ibuffer-filter): Do not store
in 'ibuffer-filtering-qualifiers' a wrong filter (Bug#25042).
* test/lisp/ibuffer-tests.el (ibuffer-test-Bug25042): Add test.

7 years ago* lisp/emacs-lisp/easy-mmode.el (define-minor-mode): Fix docstring
Philipp Stephani [Mon, 18 Apr 2016 16:32:35 +0000 (12:32 -0400)]
* lisp/emacs-lisp/easy-mmode.el (define-minor-mode): Fix docstring

so that it matches the actual implementation.
See https://lists.gnu.org/archive/html/help-gnu-emacs/2016-04/msg00071.html

7 years agoibuffer-decompose-filter-group avoid unwanted side effects
Tino Calancha [Wed, 7 Dec 2016 12:49:50 +0000 (21:49 +0900)]
ibuffer-decompose-filter-group avoid unwanted side effects

* lisp/ibuf-ext.el (ibuffer-delete-alist): Remove it.
(ibuffer-remove-alist): New defun; it supersedes 'ibuffer-delete-alist'.
All callers changed (Bug#25058).
* test/lisp/ibuffer-tests.el (ibuffer-test-Bug25058): Add test.

7 years agoibuffer-unmark-backward: Unmark the region when is active
Tino Calancha [Wed, 7 Dec 2016 12:36:38 +0000 (21:36 +0900)]
ibuffer-unmark-backward: Unmark the region when is active

* lisp/ibuffer.el (ibuffer-unmark-backward):
Use 'ibuffer-get-region-and-prefix'; call 'ibuffer-unmark-forward'
with the region boundary as the first 2 arguments (Bug#24987).

7 years agoDocstring improvement for seq-some (bug#25129)
Nicolas Petton [Wed, 7 Dec 2016 12:32:46 +0000 (13:32 +0100)]
Docstring improvement for seq-some (bug#25129)

* lisp/emacs-lisp/seq.el (seq-some): Make the docstring less confusing
  regarding the returned value.

7 years agodired-unmark-backward: Unmark the region when is active
Tino Calancha [Wed, 7 Dec 2016 12:27:31 +0000 (21:27 +0900)]
dired-unmark-backward: Unmark the region when is active

* lisp/dired.el (dired-unmark-backward): Call 'dired-unmark' with
a non-nil second argument (Bug#24986).

7 years agoNew test file for ediff
Tino Calancha [Wed, 7 Dec 2016 12:18:29 +0000 (21:18 +0900)]
New test file for ediff

Fix previous commit.
* test/lisp/vc/ediff-ptch-tests.el: New test.

7 years agoediff-context-diff-label-regexp: Detect the end of second file
Tino Calancha [Wed, 7 Dec 2016 12:07:45 +0000 (21:07 +0900)]
ediff-context-diff-label-regexp: Detect the end of second file

* lisp/vc/ediff-ptch.el (ediff-context-diff-label-regexp): Skip
'\n' in file names (Bug#25010).
* test/lisp/vc/ediff-ptch-tests.el: New file.
(ibuffer-test-bug25010): Add test for Bug#25010.

7 years agoibuffer-decompose-filter: Avoid side effects on error
Tino Calancha [Wed, 7 Dec 2016 11:47:34 +0000 (20:47 +0900)]
ibuffer-decompose-filter: Avoid side effects on error

* lisp/ibuf-ext.el (ibuffer-decompose-filter):
Update 'ibuffer-filtering-qualifiers' only if there is no error (Bug#24997).
* test/lisp/ibuffer-tests.el (ibuffer-test-Bug24997):
Update test result as pass.

7 years agoibuffer: compare marks with EQ
Tino Calancha [Wed, 7 Dec 2016 11:37:01 +0000 (20:37 +0900)]
ibuffer: compare marks with EQ

* lisp/ibuffer (ibuffer-update-title-and-summary, ibuffer-redisplay-current)
(ibuffer-buffer-name-face, ibuffer-unmark-all)
(ibuffer-count-deletion-lines, ibuffer-buffer-names-with-mark):
Use 'eq' instead of 'char-equal' when comparing mark characters (Bug#25000).
* test/lisp/ibuffer-tests.el (ibuffer-test-Bug25000):
Update test result as pass.

7 years agoibuffer-saved-filters: Remove extra nesting level
Christopher Genovese [Wed, 7 Dec 2016 10:51:33 +0000 (19:51 +0900)]
ibuffer-saved-filters: Remove extra nesting level

Fix Bug#25049.
* lisp/ibuf-ext.el (ibuffer-saved-filters): Remove extra
nesting level; add transparent setter to adjust old-format values;
update doc string.
(ibuffer-save-filters): Remove extra level of nesting
in ibuffer-saved-filters values when saving new filters.
(ibuffer-old-saved-filters-warning): New variable with
clickable message with repair options to be displayed
as a warning if 'ibuffer-repair-saved-filters' detects
a format mismatch.
(ibuffer-repair-saved-filters): Add new command to check and
repair saved filters format.
(ibuffer-included-in-filter-p, ibuffer-decompose-filter):
Change access of saved filter data (cadr->cdr) to account
for reduced nesting.
* test/lisp/ibuffer-tests.el (ibuffer-save-filters):
New test; check that filters are saved in the proper format.

7 years agoClean out some IRIX cruft
Paul Eggert [Wed, 7 Dec 2016 07:41:45 +0000 (23:41 -0800)]
Clean out some IRIX cruft

* etc/MACHINES: Remove obsolete discussion of IRIX.
* src/process.c (allocate_pty) [__sgi]: Remove SGI-specific code.
(create_process) [HAVE_PTYS]: Don't worry about IRIX.
* src/syntax.c (scan_sexps_forward): Remove obsolete comment.
* src/unexelf.c [__sgi]: Don't include <syms.h>.
(unexec) [__sgi]: Remove SGI-specific code.

7 years agoSimplify FUNCTIONP implementation
Paul Eggert [Wed, 7 Dec 2016 05:38:32 +0000 (21:38 -0800)]
Simplify FUNCTIONP implementation

* src/bytecode.c (exec_byte_code):
* src/image.c (parse_image_spec):
Prefer FUNCTIONP (x) to !NILP (Ffunctionp (x)).
* src/eval.c (FUNCTIONP): Move here ...
* src/lisp.h: ... from here.  No longer inline, as that
bloats the text and does not help speed (at least on my platform).
(functionp): Remove this name, since callers use FUNCTIONP.

7 years agoDon't assume window-point and point are the same
Noam Postavsky [Sun, 4 Dec 2016 06:06:52 +0000 (01:06 -0500)]
Don't assume window-point and point are the same

The function `cursor-sensor--detect' calls `bobp' to decide whether to
check properties at (1- (window-point)).  However, (window-point) may be
at beginning of buffer, even if (point) is not.  In this case an
`args-out-of-range' error will be signaled (Bug#25104).

* lisp/emacs-lisp/cursor-sensor.el (cursor-sensor--detect): Check the
value of (window-point) against (point-min), rather than (bobp) to
decide if (1- (window-point)) is accessible.

7 years agoGive test-completion's PREDICATE the hashtable key
Noam Postavsky [Sun, 27 Nov 2016 19:41:02 +0000 (14:41 -0500)]
Give test-completion's PREDICATE the hashtable key

For hashtable entries with symbol keys, `test-completion' would convert
the key to a string before calling PREDICATE, unlike `try-completion'
and `all-completions'.

* src/minibuf.c (Ftest_completion): Pass original key from hashtable.

7 years agoGive test-completion's PREDICATE full alist entry
Noam Postavsky [Sun, 27 Nov 2016 15:04:48 +0000 (10:04 -0500)]
Give test-completion's PREDICATE full alist entry

Since 2016-06-26 "Fix test-completion with completion-regexp-list", when
calling test-completion with an alist collection, the predicate was
recieving the string value instead of the alist entry (Bug#24966).

* src/minibuf.c (Ftest_completion): Don't modify the found element, just
test STRING against `completion-regexp-list'.
* test/src/minibuf-tests.el: New tests for `try-completion',
`all-completions', and `test-completion'.

7 years agoFix ert-tests when running compiled
Noam Postavsky [Mon, 22 Aug 2016 02:58:37 +0000 (22:58 -0400)]
Fix ert-tests when running compiled

* test/lisp/emacs-lisp/ert-tests.el (ert-test-deftest): Don't test for
specific macroexpansion, just check result of evaluation.
(ert-test-record-backtrace): Don't hardcode representation of closure in
expected backtrace, this lets the test succeed even when the test code
is compiled.

* lisp/emacs-lisp/ert.el (ert--expand-should-1): Also pass
`byte-compile-macro-environment' to `macroexpand', this allows the
`should' macro to properly handle macroexpansion of macros that were
defined in the same file when it's being compiled (Bug #17851).

7 years agoMake "g" in vc push/pull buffers re-push/pull
Glenn Morris [Wed, 7 Dec 2016 01:31:54 +0000 (20:31 -0500)]
Make "g" in vc push/pull buffers re-push/pull

* lisp/vc/vc-bzr.el (vc-bzr--pushpull):
* lisp/vc/vc-git.el (vc-git--pushpull):
* lisp/vc/vc-hg.el (vc-hg--pushpull):
Set compile-command so that "g" works.  (Bug#11446)

7 years agoChange two _Noreturn functions to return void
Paul Eggert [Tue, 6 Dec 2016 23:25:54 +0000 (15:25 -0800)]
Change two _Noreturn functions to return void

This is a bit clearer than _Noreturn functions that (do not)
return a non-void type.
* src/callproc.c (call_process) [MSDOS]:
Use 'status' local to record status.
(child_setup): Return CHILD_SETUP_TYPE.
* src/data.c, src/lisp.h (wrong_type_argument): Return void.
All callers changed.
* src/lisp.h (CHILD_SETUP_TYPE): New macro.

7 years agoFix the test suite
Eli Zaretskii [Tue, 6 Dec 2016 18:23:37 +0000 (20:23 +0200)]
Fix the test suite

* test/automated/bindings.el: Contents moved to
test/src/data-tests.el.
* test/automated/threads.el: Moved to test/src/thread-tests.el.

7 years agoFix a typo in bytecode.c.
Eli Zaretskii [Tue, 6 Dec 2016 18:11:47 +0000 (20:11 +0200)]
Fix a typo in bytecode.c.

7 years agoFix GPG bug introduced by Oct file-missing change
Paul Eggert [Tue, 6 Dec 2016 06:40:36 +0000 (22:40 -0800)]
Fix GPG bug introduced by Oct file-missing change

Problem with visiting nonexistent .gpg file
reported by Herbert J Skuhra.
* lisp/epa-file.el (epa-file--find-file-not-found-function):
(epa-file-insert-file-contents, epa-file-write-region):
Signal file-missing or file-error instead of epa-error.

7 years agoTweak recent flymake change
Glenn Morris [Tue, 6 Dec 2016 01:11:01 +0000 (20:11 -0500)]
Tweak recent flymake change

* lisp/progmodes/flymake.el (flymake-report-fatal-status):
Avoid double message when flymake-log-level >= 0.
* doc/misc/flymake.texi (Customizable variables):
No longer mention flymake-gui-warnings-enabled.

7 years agoMake TAB and M-TAB run widget-forward and widget-backward (bug#25091)
Katsumi Yamaoka [Mon, 5 Dec 2016 23:32:36 +0000 (23:32 +0000)]
Make TAB and M-TAB run widget-forward and widget-backward (bug#25091)

* lisp/gnus/mm-decode (mm-convert-shr-links): Avoid `shr-next-link'
and `shr-previous-link' so TAB and M-TAB run `widget-forward' and
`widget-backward' instead (bug#25091).

7 years agoFix compilation problems.
Eli Zaretskii [Mon, 5 Dec 2016 20:50:44 +0000 (22:50 +0200)]
Fix compilation problems.

7 years agoFix merged code in process.c and eval.c.
Eli Zaretskii [Mon, 5 Dec 2016 18:59:11 +0000 (20:59 +0200)]
Fix merged code in process.c and eval.c.

7 years agoRemove compat code in Tramp
Michael Albinus [Mon, 5 Dec 2016 15:06:04 +0000 (16:06 +0100)]
Remove compat code in Tramp

* lisp/net/tramp.el (tramp-parse-time-months): Remove.

* lisp/net/tramp-compat.el (top): Require parse-time.

* lisp/net/tramp-smb.el (tramp-smb-read-file-entry):
Use `parse-time-months'.

7 years agoDon't try to split side windows in ibuffer (Bug#25115)
Martin Rudalics [Mon, 5 Dec 2016 10:06:55 +0000 (11:06 +0100)]
Don't try to split side windows in ibuffer (Bug#25115)

* lisp/ibuffer.el (ibuffer-confirm-operation-on): Don't try to
split a side window (Bug#25115).

7 years ago* src/lisp.h: Update comment to kick -Og down the road.
Paul Eggert [Mon, 5 Dec 2016 02:19:01 +0000 (18:19 -0800)]
* src/lisp.h: Update comment to kick -Og down the road.

7 years agoMore image-dired refactoring
Mark Oteiza [Sun, 4 Dec 2016 18:43:03 +0000 (13:43 -0500)]
More image-dired refactoring

* lisp/image-dired.el: Remove TODO comment. This appears to have been
implemented in 5d7433a "image-dired: Signal an error before calling a
missing executable".
(image-dired-cmd-create-standard-thumbnail-command): Use %p specifier.
Add :version.
(image-dired-display-thumbs, image-dired-create-thumbs): Use dolist and
when. Remove superfluous call to image-dired-thumb-name. Move single nil
binding and setq into dolist form.

7 years agoMerge branch 'concurrency'
Eli Zaretskii [Sun, 4 Dec 2016 17:59:17 +0000 (19:59 +0200)]
Merge branch 'concurrency'

Conflicts (resolved):
configure.ac
src/Makefile.in
src/alloc.c
src/bytecode.c
src/emacs.c
src/eval.c
src/lisp.h
src/process.c
src/regex.c
src/regex.h

7 years agoImplement quoting the local part of a remote file name
Michael Albinus [Sun, 4 Dec 2016 11:12:06 +0000 (12:12 +0100)]
Implement quoting the local part of a remote file name

* doc/emacs/files.texi (Quoted File Names):
* etc/NEWS: Mention quoting the local part of a remote file name.

* lisp/net/tramp.el (tramp-dissect-file-name): Check with
`tramp-tramp-file-p'.
(tramp-quoted-name-p, tramp-quote-name, tramp-unquote-name):
New defsubst.
(tramp-handle-substitute-in-file-name)
(tramp-handle-make-auto-save-file-name): Handle quoted files.
(tramp-shell-quote-argument): Unquote argument.

* lisp/net/tramp-sh.el (tramp-sh-handle-file-truename):
Handle quoted files.

* test/lisp/net/tramp-tests.el (tramp--test-expensive-test): New defvar.
(tramp--test-make-temp-name): New argument QUOTED.
(tramp-test01-file-name-syntax)
(tramp-test02-file-name-dissect)
(tramp-test04-substitute-in-file-name)
(tramp-test05-expand-file-name, tramp-test07-file-exists-p)
(tramp-test08-file-local-copy)
(tramp-test09-insert-file-contents)
(tramp-test10-write-region, tramp-test11-copy-file)
(tramp-test12-rename-file, tramp-test13-make-directory)
(tramp-test14-delete-directory, tramp-test15-copy-directory)
(tramp-test16-directory-files)
(tramp-test17-insert-directory)
(tramp-test18-file-attributes)
(tramp-test19-directory-files-and-attributes)
(tramp-test20-file-modes, tramp-test21-file-links)
(tramp-test22-file-times, tramp-test23-visited-file-modtime)
(tramp-test24-file-name-completion, tramp-test25-load)
(tramp-test26-process-file, tramp-test27-start-file-process)
(tramp-test28-shell-command, tramp-test30-vc-registered)
(tramp-test31-make-auto-save-file-name)
(tramp--test-check-files)
(tramp-test35-asynchronous-requests): Test also quoted file names.
(tramp--test-shell-command-to-string-asynchronously): Rename.
(tramp-test29-environment-variables): Use it.

7 years agoFix typo in dired-omit-case-fold-p
Tino Calancha [Sun, 4 Dec 2016 09:12:59 +0000 (18:12 +0900)]
Fix typo in dired-omit-case-fold-p

* lisp/dired-x.el (dired-omit-case-fold-p):
Write 'file-name-case-insensitive-p' instead of
'file-name-case-sensitive-p'.
Add declaration of 'file-name-case-insensitive-p'.

7 years agoAdd HTML5 attributes for the input element
Simen Heggestøyl [Sun, 4 Dec 2016 08:34:19 +0000 (09:34 +0100)]
Add HTML5 attributes for the input element

* lisp/textmodes/sgml-mode.el (html-tag-alist): Add HTML5 attributes
for the input element.

7 years agoObsolete sc-load-hook in favor of eval-after-load
Glenn Morris [Sun, 4 Dec 2016 03:27:41 +0000 (19:27 -0800)]
Obsolete sc-load-hook in favor of eval-after-load

* lisp/mail/supercite.el (sc-load-hook): Make obsolete.
* doc/misc/sc.texi (Getting Connected, Filling Cited Text):
No longer mention sc-load-hook.

7 years agoObsolete calendar-load-hook in favor of eval-after-load
Glenn Morris [Sun, 4 Dec 2016 03:22:37 +0000 (19:22 -0800)]
Obsolete calendar-load-hook in favor of eval-after-load

* lisp/calendar/calendar.el (calendar-load-hook): Make obsolete.
(calendar): Doc fix - no longer mention calendar-load-hook.
* doc/emacs/cal-xtra.texi (Calendar Customizing):
No longer mention calendar-load-hook.
* doc/lispintro/emacs-lisp-intro.texi (X11 Colors):
Replace calendar-load-hook in example with with-eval-after-load.