Chong Yidong [Fri, 23 Nov 2012 08:33:20 +0000 (16:33 +0800)]
Add some missing find options to find-cmd.el.
* find-cmd.el (find-constituents): Add executable, ipath,
readable, samefile, writable, daystart, regextype.
Fixes: debbugs:12856
Paul Eggert [Fri, 23 Nov 2012 08:28:06 +0000 (00:28 -0800)]
movemail: treat EACCES etc. failures as permanent
* movemail.c (main): Treat any link failure other than EEXIST as a
permanent failure, not just EPERM. EACCES, for example.
Paul Eggert [Fri, 23 Nov 2012 07:48:43 +0000 (23:48 -0800)]
Assume POSIX 1003.1-1988 or later for dirent.h.
* admin/CPP-DEFINES (HAVE_CLOSEDIR, HAVE_DIRENT_H): Remove.
* admin/notes/copyright: Adjust to src/ndir.h -> nt/inc/dirent.h renaming.
* configure.ac: Do not check for dirent.h or closdir.
* nt/inc/dirent.h: Rename from ../src/ndir.h, with these changes:
(struct dirent): Rename from struct direct. All uses changed.
* nt/inc/sys/dir.h: Remove.
* src/dired.c: Assume HAVE_DIRENT_H.
(NAMLEN): Remove, replacing with ...
(dirent_namelen): New function. All uses changed. Use the GNU macro
_D_EXACT_NAMELEN if available, as it's faster than strlen.
(DIRENTRY): Remove, replacing all uses with 'struct dirent'.
(DIRENTRY_NONEMPTY): Remove. All callers now assume it's nonzero.
* src/makefile.w32-in (DIR_H): Remove. All uses replaced with
$(NT_INC)/dirent.h.
($(BLD)/w32.$(O)): Do not depend on $(SRC)/ndir.h.
* src/ndir.h: Rename to ../nt/inc/dirent.h.
* src/sysdep.h (closedir) [!HAVE_CLOSEDIR]: Remove.
Do not include <dirent.h>; no longer needed.
* src/w32.c: Include <dirent.h> rather than "ndir.h".
Fixes: debbugs:12958
Paul Eggert [Fri, 23 Nov 2012 07:31:58 +0000 (23:31 -0800)]
Add Bug# to Nov 17 ChangeLog entries.
Chong Yidong [Fri, 23 Nov 2012 06:23:28 +0000 (14:23 +0800)]
* xftfont.c (xftfont_open): Remove duplicate assignment.
Stefan Monnier [Fri, 23 Nov 2012 03:26:09 +0000 (22:26 -0500)]
* emacs-lisp/ert.el, emacs-lisp/ert-x.el: Use cl-lib and lexical-binding.
Glenn Morris [Thu, 22 Nov 2012 11:17:34 +0000 (06:17 -0500)]
Auto-commit of generated files.
Dmitry Antipov [Thu, 22 Nov 2012 09:32:32 +0000 (13:32 +0400)]
* alloc.c (Fgarbage_collect): Unblock input after clearing
gc_in_progress to avoid note_mouse_highlight glitch with GC.
* frame.h (FRAME_MOUSE_UPDATE): New macro.
* msdos.c (IT_frame_up_to_date): Use it here...
* w32term.c (w32_frame_up_to_date): ...here...
* xterm.c (XTframe_up_to_date): ...and here...
* nsterm.m (ns_frame_up_to_date): ...but not here.
* lisp.h (Mouse_HLInfo): Remove mouse_face_deferred_gc member.
Adjust users.
* xdisp.c (message2_nolog, message3_nolog, note_mouse_highlight):
Do not check whether GC is in progress.
Paul Eggert [Thu, 22 Nov 2012 08:39:27 +0000 (00:39 -0800)]
Document Calc Gregorian in NEWS; fix manual a bit.
Paul Eggert [Thu, 22 Nov 2012 08:09:03 +0000 (00:09 -0800)]
* calc/calc.el (calc-gregorian-switch): In menu, put dates before regions.
This is easier to follow, lines up better in the menu, and lets us
coalesce regions that switch at the same time. Give country
names, not "Vatican", as that's better for non-expert users. Use
names that are stable between the date of switch and now, e.g.,
Bohemia and Moravia (which existed then and now) and not
Czechoslovakia (which didn't exist then and doesn't exist now).
What is now the U.S. mostly did not switch at the same time as
Britain, so omit the U.S. Correct spelling of "Britain".
Catholic Switzerland was too much of a mess, so omit it.
Paul Eggert [Thu, 22 Nov 2012 07:31:45 +0000 (23:31 -0800)]
* calc/calc.el (calc-gregorian-switch): Move to after calc-refresh
definition. This fixes a bootstrap failure.
Dmitry Antipov [Thu, 22 Nov 2012 06:52:30 +0000 (10:52 +0400)]
* xdisp.c (window_buffer_changed): New function.
(update_menu_bar, update_tool_bar): Use it to
simplify large 'if' statements.
(redisplay_internal): Generalize commonly used
'tail' and 'frame' local variables.
Eli Zaretskii [Thu, 22 Nov 2012 03:56:38 +0000 (05:56 +0200)]
Fix MS-Windows build following 2012-11-21T21:06:52Z!eggert@cs.ucla.edu.
src/w32.c (getcwd): Fix the 2nd argument type, to prevent conflicts
with Windows system header.
Fixes: debbugs:12945
Jay Belanger [Thu, 22 Nov 2012 01:47:04 +0000 (19:47 -0600)]
* doc/misc/calc.texi (Date Forms): Mention the customizable
Gregorian-Julian switch.
(Customizing Calc): Mention the variable `calc-gregorian-switch'.
* calc/calc.el (calc-gregorian-switch): Refresh the Calc buffer
after the variable is changed.
Daniel Colascione [Wed, 21 Nov 2012 21:47:10 +0000 (13:47 -0800)]
Teach sql-mode's imenu about IF NOT EXISTS
Daniel Colascione [Wed, 21 Nov 2012 21:38:56 +0000 (13:38 -0800)]
Support IF NOT EXISTS in SQL declarations
Paul Eggert [Wed, 21 Nov 2012 21:06:52 +0000 (13:06 -0800)]
Assume POSIX 1003.1-1988 or later for unistd.h.
* admin/CPP-DEFINES (BROKEN_GETWD, HAVE_GETCWD, HAVE_GETWD, HAVE_SIZE_T)
(HAVE_UNISTD_H): Remove.
* configure.ac: Do not check for getcwd or getwd.
* lib-src/emacsclient.c (getcwd): Remove decl.
(get_current_dir_name): Assume getcwd exists.
* lib-src/etags.c (HAVE_GETCWD): Remove.
(getcwd): Remove decl.
(NO_LONG_OPTIONS): Remove this. All uses removed.
Emacs always has GNU getopt.
(etags_getcwd): Assume getcwd exists.
* lib-src/movemail.c (F_OK, X_OK, W_OK, R_OK): Remove.
* nt/config.nt (HAVE_GETCWD): Remove.
* src/alloc.c: Assume unistd.h exists.
* src/fileio.c (Fexpand_file_name) [DOS_NT]: Use getcwd, not getwd.
* src/sysdep.c (get_current_dir_name): Assume getcwd exists.
(getwd) [USG]: Remove; no longer needed.
(sys_subshell) [DOS_NT]: Use getcwd, not getwd.
* src/w32.c (getcwd): Rename from getwd, and switch to getcwd's API.
* src/w32.h (getcwd): Remove decl.
Fixes: debbugs:12945
Stefan Monnier [Wed, 21 Nov 2012 16:34:35 +0000 (11:34 -0500)]
* src/xdisp.c (fast_set_selected_frame): Rename from update_tool_bar_unwind.
Make it set selected_window as well.
(update_tool_bar): Use it.
Glenn Morris [Wed, 21 Nov 2012 11:17:40 +0000 (06:17 -0500)]
Auto-commit of generated files.
Glenn Morris [Wed, 21 Nov 2012 08:39:08 +0000 (00:39 -0800)]
Add optional "inherit" argument for face-bold-p and related functions
* lisp/faces.el (face-underline-p, face-inverse-video-p, face-bold-p)
(face-italic-p): Add optional argument "inherit".
* doc/lispref/display.texi (Attribute Functions):
Add new "inherit" argument for face-bold-p etc.
Move description of this argument to a common section, like "frame".
Glenn Morris [Wed, 21 Nov 2012 08:27:13 +0000 (00:27 -0800)]
Remove -p suffix from set-face-* functions
* lisp/faces.el (set-face-inverse-video, set-face-bold, set-face-italic):
Remove -p suffix from names, for consistency with other set-face-*.
(set-face-inverse-video): Fix interactive spec.
* lisp/play/gamegrid.el (gamegrid-make-mono-tty-face):
* lisp/textmodes/table.el (table--update-cell-face):
Use set-face-inverse-video rather than now obsolete alias.
* doc/lispref/display.texi (Attribute Functions):
Update for set-face-* name changes.
Glenn Morris [Wed, 21 Nov 2012 04:47:55 +0000 (20:47 -0800)]
Merge from emacs-24; up to 2012-11-17T22:12:47Z!eggert@cs.ucla.edu
Glenn Morris [Wed, 21 Nov 2012 01:52:03 +0000 (20:52 -0500)]
Add a bit more about profiling to the lispref
* doc/lispref/debugging.texi (Profiling):
Add some basic information about the profile report buffer.
(Debugging): Mention profiling in the introduction.
Glenn Morris [Wed, 21 Nov 2012 01:32:09 +0000 (20:32 -0500)]
* doc/lispref/debugging.texi (Profiling) [!tex]: Mention --enable-profiling.
Glenn Morris [Wed, 21 Nov 2012 01:22:09 +0000 (20:22 -0500)]
* configure.ac (--enable-profiling): Doc fix.
Stefan Monnier [Tue, 20 Nov 2012 20:06:17 +0000 (15:06 -0500)]
Conflate Qnil and Qunbound for `symbol-function'.
* src/alloc.c (Fmake_symbol): Initialize `function' to Qnil.
* src/lread.c (init_obarray): Set `function' fields to Qnil.
* src/eval.c (Fcommandp): Ignore Qunbound.
(Fautoload, eval_sub, Fapply, Ffuncall, Fmacroexpand):
* src/data.c (Ffset, Ffboundp, indirect_function, Findirect_function):
Test NILP rather than Qunbound.
(Ffmakunbound): Set to Qnil.
(Fsymbol_function): Never signal an error.
(Finteractive_form): Ignore Qunbound.
Stefan Monnier [Tue, 20 Nov 2012 19:32:20 +0000 (14:32 -0500)]
* lisp/uniquify.el (uniquify-managed): Use defvar-local.
(rename-buffer, create-file-buffer): Advise with advice-add.
(uniquify-unload-function): Unadvise accordingly.
Stefan Monnier [Tue, 20 Nov 2012 19:30:37 +0000 (14:30 -0500)]
* lisp/emacs-lisp/trace.el: Rewrite, use nadvice and lexical-binding.
(trace-buffer): Don't purecopy.
(trace-entry-message, trace-exit-message): Add `context' arg.
(trace--timer): New var.
(trace-make-advice): Adjust for use in nadvice.
Add `context' argument. Delay `display-buffer' via a timer.
(trace-function-internal): Use advice-add.
(trace--read-args): New function.
(trace-function-foreground, trace-function-background): Use it.
(trace-function): Rename to trace-function-foreground and redefine as
an alias to that new name.
(untrace-function, untrace-all): Adjust to the use of nadvice.
Daniel Colascione [Tue, 20 Nov 2012 19:28:53 +0000 (11:28 -0800)]
Backport: Rename cygwin_convert_path* to cygwin_convert_file_name*
Stefan Monnier [Tue, 20 Nov 2012 19:05:20 +0000 (14:05 -0500)]
* lisp/emacs-lisp/bytecomp.el (byte-compile): Fix handling of closures.
Stefan Monnier [Tue, 20 Nov 2012 17:54:00 +0000 (12:54 -0500)]
* lisp/emacs-lisp/byte-run.el (defun-declarations-alist): Fix last change.
Eli Zaretskii [Tue, 20 Nov 2012 17:44:04 +0000 (19:44 +0200)]
Fix bug #12927 with scrolling under hl-line-mode and scroll-conservatively.
lisp/simple.el (line-move): Don't call line-move-partial if
scroll-conservatively is in effect.
Eli Zaretskii [Tue, 20 Nov 2012 17:13:10 +0000 (19:13 +0200)]
Fix !ifdef in nmake.defs.
nt/nmake.defs: Use !if, not !ifdef. See
http://lists.gnu.org/archive/html/help-emacs-windows/2012-11/msg00027.html
for the details.
Eli Zaretskii [Tue, 20 Nov 2012 17:07:55 +0000 (19:07 +0200)]
Yet more fixes for bug #12878 with MSVC build.
nt/inc/stdint.h (INTPTR_MIN): Define for MSVC.
Ken Brown [Tue, 20 Nov 2012 13:26:40 +0000 (08:26 -0500)]
Fix non-GTK builds on Cygwin
* src/emacs.c (main): Set the G_SLICE environment variable for all
Cygwin builds, not just GTK builds. See
https://lists.gnu.org/archive/html/emacs-devel/2012-11/msg00368.html.
Dmitry Antipov [Tue, 20 Nov 2012 11:41:57 +0000 (15:41 +0400)]
Tiny adjustment around the previous redisplay change.
* xdisp.c (window_outdated): New function.
(text_outside_line_unchanged_p, redisplay_window): Use it.
(redisplay_internal): Likewise. Fix indentation.
Glenn Morris [Tue, 20 Nov 2012 11:17:33 +0000 (06:17 -0500)]
Auto-commit of generated files.
Michael Albinus [Tue, 20 Nov 2012 09:29:47 +0000 (10:29 +0100)]
* trampver.el:
* trampver.texi: Downgrade version to 2.2.6-24.3, in order to
distinguish from trunk.
Don't merge with trunk, please.
Glenn Morris [Tue, 20 Nov 2012 08:47:57 +0000 (00:47 -0800)]
Fix typos in previous
Glenn Morris [Tue, 20 Nov 2012 08:39:41 +0000 (00:39 -0800)]
NEWS fix
Ref: http://lists.gnu.org/archive/html/emacs-devel/2012-11/msg00377.html
Paul Eggert [Tue, 20 Nov 2012 08:32:19 +0000 (00:32 -0800)]
* eval.c (interactive_p): Remove no-longer-used decl.
Paul Eggert [Tue, 20 Nov 2012 08:31:19 +0000 (00:31 -0800)]
* emacsclient.c (handle_sigcont, handle_sigtstp): Use raise (sig)
rather than kill (getpid (), sig), as it's simpler and safer.
Paul Eggert [Tue, 20 Nov 2012 08:29:04 +0000 (00:29 -0800)]
Omit -Wstrict-overflow as it does not play well with --enable-checking.
Glenn Morris [Tue, 20 Nov 2012 08:02:54 +0000 (00:02 -0800)]
Make a start on a Profiling section in the lispref
* doc/lispref/debugging.texi (Profiling): New section, in progress.
* doc/lispref/tips.texi (Compilation Tips): Move profiling to separate section.
* doc/lispref/elisp.texi: Add Profiling to detailed menu.
Dmitry Antipov [Tue, 20 Nov 2012 07:53:04 +0000 (11:53 +0400)]
* xdisp.c (buffer_shared): Adjust comment.
(buffer_shared_and_changed): New function.
(prepare_menu_bars, redisplay_internal): Use it to
decide whether all windows or frames should be updated.
Stefan Monnier [Tue, 20 Nov 2012 04:24:09 +0000 (23:24 -0500)]
Make called-interactively-p work for edebug or advised code.
* lisp/subr.el (called-interactively-p-functions): New var.
(internal--called-interactively-p--get-frame): New macro.
(called-interactively-p, interactive-p): Rewrite in Lisp.
* lisp/emacs-lisp/nadvice.el (advice--called-interactively-skip): New fun.
(called-interactively-p-functions): Use it.
* lisp/emacs-lisp/edebug.el (edebug--called-interactively-skip): New fun.
(called-interactively-p-functions): Use it.
* lisp/allout.el (allout-called-interactively-p): Don't assume
called-interactively-p is a subr.
* src/eval.c (Finteractive_p, Fcalled_interactively_p, interactive_p): Remove.
(syms_of_eval): Remove corresponding defsubr.
* src/bytecode.c (exec_byte_code): `interactive-p' is now a Lisp function.
* test/automated/advice-tests.el (advice-tests--data): Remove.
(advice-tests): Move the tests directly here instead.
Add called-interactively-p tests.
Glenn Morris [Tue, 20 Nov 2012 00:57:23 +0000 (19:57 -0500)]
Add a menu for profiler report mode
* lisp/profiler.el (profiler-report-mode-map): Add a menu.
No need to bind `q' because we derive from special-mode.
(profiler-report-find-entry): Handle calls from the menu-bar.
Paul Eggert [Mon, 19 Nov 2012 23:39:28 +0000 (15:39 -0800)]
Improve static checking of integer overflow and stack smashing.
* configure.ac (WARN_CFLAGS): Add -Wstack-protector and
-Wstrict-overflow if using GCC 4.7.2 or later on a platform with
at least 64-bit long int. This improves static checking on these
platforms, when configured with --enable-gcc-warnings.
Stefan Monnier [Mon, 19 Nov 2012 21:30:55 +0000 (16:30 -0500)]
* lisp/emacs-lisp/byte-run.el (defun-declarations-alist):
Allow compiler-macros to be lambda expressions.
* lisp/progmodes/python.el: Use cl-lib. Move var declarations outside of
eval-when-compile.
(python-syntax-context): Add compiler-macro.
(python-font-lock-keywords): Simplify with De Morgan.
Stefan Monnier [Mon, 19 Nov 2012 20:57:36 +0000 (15:57 -0500)]
* lisp/emacs-lisp/byte-run.el (defun-declarations-alist): Don't accept
non-symbols for compiler macros (yet).
Stefan Monnier [Mon, 19 Nov 2012 19:22:07 +0000 (14:22 -0500)]
* lisp/eshell/em-cmpl.el (eshell-pcomplete): Refine fix for bug#12838:
Fallback on completion-at-point rather than
pcomplete-expand-and-complete, and only if pcomplete actually failed.
(eshell-cmpl-initialize): Setup completion-at-point.
* lisp/pcomplete.el (pcomplete--entries): Obey pcomplete-ignore-case.
Stefan Monnier [Mon, 19 Nov 2012 18:40:18 +0000 (13:40 -0500)]
* lisp/vc/diff-mode.el (diff-hunk): Don't make useless timers.
Stefan Monnier [Mon, 19 Nov 2012 18:27:25 +0000 (13:27 -0500)]
* lisp/files.el (load-file): Require match in minibuffer selection, as was
the case in Emacs-20 before we changed the spec to allow .elc files.
Fixes: debbugs:12935
Eli Zaretskii [Mon, 19 Nov 2012 17:34:21 +0000 (19:34 +0200)]
More fixes for bug #12878 with MS-Windows MSVC build.
src/xdisp.c (start_hourglass) [HAVE_NTGUI]: Don't mix declaration of
w32_note_current_window with code. (Backport from trunk.)
src/w32.c (FILE_DEVICE_FILE_SYSTEM, METHOD_BUFFERED)
(FILE_ANY_ACCESS, CTL_CODE, FSCTL_GET_REPARSE_POINT) [_MSC_VER]:
Define for the MSVC compiler.
src/w32term.h (EnumSystemLocalesW) [_MSC_VER]: Add a missing
semi-colon.
nt/inc/stdint.h (PTRDIFF_MIN) [!__GNUC__]: Define for MSVC.
Stefan Monnier [Mon, 19 Nov 2012 17:24:12 +0000 (12:24 -0500)]
Use cl-lib instead of cl, and interactive-p => called-interactively-p.
* lisp/erc/erc-track.el, lisp/erc/erc-networks.el, lisp/erc/erc-netsplit.el:
* lisp/erc/erc-dcc.el, lisp/erc/erc-backend.el: Use cl-lib, nth, pcase, and
called-interactively-p instead of cl.
* lisp/erc/erc-speedbar.el, lisp/erc/erc-services.el:
* lisp/erc/erc-pcomplete.el, lisp/erc/erc-notify.el, lisp/erc/erc-match.el:
* lisp/erc/erc-log.el, lisp/erc/erc-join.el, lisp/erc/erc-ezbounce.el:
* lisp/erc/erc-capab.el: Don't require cl since we don't use it.
* lisp/erc/erc.el: Use cl-lib, nth, pcase, and called-interactively-p i.s.o cl.
(erc-lurker-ignore-chars, erc-common-server-suffixes): Move before first use.
* lisp/json.el: Don't require cl since we don't use it.
* lisp/color.el: Don't require cl.
(color-complement): `caddr' -> `nth 2'.
* test/automated/ert-x-tests.el: Use cl-lib.
* test/automated/ert-tests.el: Use lexical-binding and cl-lib.
Stefan Monnier [Mon, 19 Nov 2012 17:02:20 +0000 (12:02 -0500)]
* lisp/emacs-lisp/ert.el (ert--expand-should-1): Adapt to cl-lib.
Stefan Monnier [Mon, 19 Nov 2012 16:17:49 +0000 (11:17 -0500)]
* lisp/calendar/time-date.el (time-to-seconds): De-obsolete.
Stefan Monnier [Mon, 19 Nov 2012 16:16:07 +0000 (11:16 -0500)]
* lisp/cedet/semantic/fw.el (semantic-make-local-hook)
(semantic-mode-line-update): Simplify via CSE.
Michael Albinus [Mon, 19 Nov 2012 15:25:10 +0000 (16:25 +0100)]
* net/tramp-sh.el (tramp-do-copy-or-rename-file): If both files
are remote, check out-of-band property for both.
Katsumi Yamaoka [Mon, 19 Nov 2012 11:36:02 +0000 (11:36 +0000)]
message.el (message-get-reply-headers): Fix typo in comment
Katsumi Yamaoka [Mon, 19 Nov 2012 06:24:14 +0000 (06:24 +0000)]
message.el (message-get-reply-headers): Make sure the reply goes to the author if it is a wide reply
Jay Belanger [Mon, 19 Nov 2012 05:03:08 +0000 (23:03 -0600)]
* calc/calc-forms.el (math-leap-year-p): Fix formula for negative
year numbers.
(math-date-to-julian-dt): Adjust the initial approximation for the
year to deal with the new definition of the DATE.
Stefan Monnier [Mon, 19 Nov 2012 03:16:03 +0000 (22:16 -0500)]
* lisp/window.el (switch-to-buffer): Re-add the warning that was lost in the
code rewrite.
Daniel Colascione [Mon, 19 Nov 2012 01:39:37 +0000 (17:39 -0800)]
Rename cygwin_convert_path* to cygwin_convert_file_name*
Paul Eggert [Sun, 18 Nov 2012 17:10:35 +0000 (09:10 -0800)]
More minor time fixes.
* calendar/time-date.el: Commentary fix.
* net/tramp-sh.el (tramp-do-file-attributes-with-ls): Undo last change;
too much other code depends on (0 0) time stamps.
* net/tramp.el (tramp-time-less-p, tramp-time-subtract):
Add a couple of FIXME comments.
Eli Zaretskii [Sun, 18 Nov 2012 16:54:31 +0000 (18:54 +0200)]
Fix latest changes in nt/inc/unistd.h.
nt/inc/unistd.h: Don't include fcntl.h and don't define O_RDWR.
Fixes: debbugs:12881
Eli Zaretskii [Sun, 18 Nov 2012 16:43:36 +0000 (18:43 +0200)]
Prevent crashes on MS-Windows when w32-downcase-file-names is non-nil.
src/fileio.c (Fsubstitute_in_file_name, Ffile_name_directory)
(Fexpand_file_name) [DOS_NT]: Pass encoded file name to
dostounix_filename. Prevents crashes down the road, because
dostounix_filename assumes it gets a unibyte string. Reported by
Michel de Ruiter <michel@sentient.nl>, see
http://lists.gnu.org/archive/html/help-emacs-windows/2012-11/msg00017.html
Martin Rudalics [Sun, 18 Nov 2012 11:34:36 +0000 (12:34 +0100)]
Fix example for Display Action Functions.
* windows.texi (Display Action Functions): Fix recently added
example. Suggested by Michael Heerdegen.
Glenn Morris [Sun, 18 Nov 2012 11:19:05 +0000 (06:19 -0500)]
Auto-commit of generated files.
Dani Moncayo [Sun, 18 Nov 2012 06:27:43 +0000 (14:27 +0800)]
Emacs manual fixes regarding automatic scrolling.
* display.texi (Auto Scrolling): Fix some inaccuracies, plus
clarifications.
(Horizontal Scrolling): Clarifications.
Fixes: debbugs:12865
Chong Yidong [Sun, 18 Nov 2012 05:38:13 +0000 (13:38 +0800)]
Avoid using "X" interactive flag in filecache.el.
* filecache.el (file-cache--read-list): New function.
(file-cache-add-directory-list, file-cache-add-file-list)
(file-cache-delete-file-list, file-cache-delete-directory-list):
Use it to read a list of files or directories.
(file-cache-add-file, file-cache-add-directory)
(file-cache-delete-file-list, file-cache-delete-file-regexp)
(file-cache-delete-directory): Print an message.
Fixes: debbugs:12846
Jay Belanger [Sun, 18 Nov 2012 03:59:00 +0000 (21:59 -0600)]
* calc/calc-forms.el (math-date-to-dt): Use integer date
when calling `math-date-to-julian-dt' and 'math-date-to-gregorian-dt'.
Paul Eggert [Sun, 18 Nov 2012 02:29:09 +0000 (18:29 -0800)]
* nsterm.m (ns_select): Send SIGIO only to self, not to process group.
Glenn Morris [Sun, 18 Nov 2012 02:19:43 +0000 (18:19 -0800)]
ChangeLog Merge fix
Paul Eggert [Sun, 18 Nov 2012 02:13:19 +0000 (18:13 -0800)]
Minor cleanup for times as lists of four integers.
* doc/lispref/os.texi (Time Parsing): Time values can now be four integers.
* lisp/files.el (dir-locals-directory-cache):
* lisp/ps-bdf.el (bdf-file-mod-time, bdf-read-font-info):
Doc fixes.
* lisp/net/tramp-sh.el (tramp-do-file-attributes-with-ls):
* lisp/ps-bdf.el (bdf-file-newer-than-time):
Process four-integers time stamps, not two. Doc fixes.
Glenn Morris [Sun, 18 Nov 2012 01:52:36 +0000 (17:52 -0800)]
Merge from emacs-24; up to 2012-11-15T23:31:37Z!dancol@dancol.org
Glenn Morris [Sun, 18 Nov 2012 01:45:44 +0000 (17:45 -0800)]
NEWS tweak
Glenn Morris [Sun, 18 Nov 2012 01:43:32 +0000 (17:43 -0800)]
* lisp/image.el (insert-image, insert-sliced-image): Doc fix.
Glenn Morris [Sun, 18 Nov 2012 01:38:42 +0000 (17:38 -0800)]
Document eager macro expansion
* doc/lispref/loading.texi (How Programs Do Loading): Add eager macro expansion.
* doc/lispref/macros.texi (Expansion): Mention eager macro expansion.
* etc/NEWS: Related edit.
Juanma Barranquero [Sun, 18 Nov 2012 01:20:04 +0000 (02:20 +0100)]
Silence some warnings.
lisp/woman.el (woman-non-underline-faces): Use `set-face-underline'.
lisp/calc/calc.el (math-format-date-cache): Declare.
Juanma Barranquero [Sun, 18 Nov 2012 01:12:17 +0000 (02:12 +0100)]
src/w32proc.c (waitpid): Remove unused label get_result.
Juanma Barranquero [Sat, 17 Nov 2012 23:58:56 +0000 (00:58 +0100)]
nt/config.nt: Sync with autogen/config.in.
(HAVE_FPATHCONF): Remove.
Glenn Morris [Sat, 17 Nov 2012 23:29:29 +0000 (15:29 -0800)]
* minibuf.texi (Basic Completion): Mention completion-table-with-quoting
Glenn Morris [Sat, 17 Nov 2012 23:24:36 +0000 (15:24 -0800)]
Add some cindex entries for previous change
Juanma Barranquero [Sat, 17 Nov 2012 23:16:24 +0000 (00:16 +0100)]
lib-src/makefile.w32-in, src/makefile.w32-in: Update dependencies.
* lib-src/makefile.w32-in (SYSWAIT_H): New macro.
($(BLD)/movemail.$(O)): Update dependencies.
* src/makefile.w32-in (SYSWAIT_H): New macro.
($(BLD)/callproc.$(O), $(BLD)/w32proc.$(O), $(BLD)/process.$(O))
($(BLD)/sysdep.$(O)): Update dependencies.
Glenn Morris [Sat, 17 Nov 2012 22:45:24 +0000 (14:45 -0800)]
* minibuf.texi (Basic Completion): Mention misc completion-table funcs.
* etc/NEWS: Related edit.
Paul Eggert [Sat, 17 Nov 2012 22:12:47 +0000 (14:12 -0800)]
Assume POSIX 1003.1-1988 or later for fcntl.h.
* admin/CPP-DEFINES (O_RDONLY, O_RDWR, HAVE_FCNTL_H): Remove.
* admin/merge-gnulib (GNULIB_MODULES): Add fcntl-h.
* configure.ac: Do not check for fcntl.h.
* lib/gnulib.mk: Regenerate.
* lib-src/movemail.c, lib-src/update-game-score.c: Assume <fcntl.h> exists.
* nt/inc/sys/socket.h (O_NONBLOCK): Rename from O_NDELAY, since the
POSIX name for this flag is O_NONBLOCK. All uses changed.
* nt/inc/unistd.h (O_RDWR, O_NOCTTY): New macros. Like AT_FDCWD etc.
these really should be moved to a replacement <fcntl.h> if and
when that gets implemented. In the meantime, include <fcntl.h>
to make sure we don't override its definitions.
* src/callproc.c (relocate_fd): Assume F_DUPFD.
* src/emacs.c, src/term.c (O_RDWR): Remove.
* src/keyboard.c (tty_read_avail_input): Use O_NONBLOCK rather than
O_NDELAY, since O_NONBLOCK is the standard name for this flag.
* src/nsterm.m: Assume <fcntl.h> exists.
* src/process.c (NON_BLOCKING_CONNECT, allocate_pty, create_process)
(create_pty, Fmake_network_process, server_accept_connection)
(wait_reading_process_output, init_process_emacs):
Assume O_NONBLOCK.
(wait_reading_process_output): Put in a special case for WINDOWSNT
to mimick the older behavior where it had O_NDELAY but not O_NONBLOCK.
It's not clear this is needed, but it's a more-conservative change.
(create_process): Assume FD_CLOEXEC.
(create_process, create_pty): Assume O_NOCTTY.
* src/sysdep.c (init_sys_modes, reset_sys_modes): Assume F_SETFL.
(reset_sys_modes): Use O_NONBLOCK rather than O_NDELAY.
Omit if not DOS_NT, since F_GETFL is not defined there.
(serial_open): Assume O_NONBLOCK and O_NOCTTY.
* src/term.c: Include <fcntl.h>, for flags like O_NOCTTY.
(O_NOCTTY): Remove.
(init_tty): Assume O_IGNORE_CTTY is defined to 0 on platforms that
lack it, since gnulib guarantees this.
* src/w32.c (fcntl): Test for O_NONBLOCK rather than O_NDELAY.
Fixes: debbugs:12881
Paul Eggert [Sat, 17 Nov 2012 22:01:59 +0000 (16:01 -0600)]
Calc now uses the Gregorian calendar for all dates,
and uses January 1, 1 AD as its day number 1.
* doc/misc/calc.texi (Date Forms): Document this.
* lisp/calc/calc-forms.el (math-julian-date-beginning)
(math-julian-date-beginning-int): Implement this.
Juanma Barranquero [Sat, 17 Nov 2012 21:52:12 +0000 (22:52 +0100)]
lisp/*.el: Add missing declarations.
* descr-text.el (quail-find-key):
* dired.el (desktop-file-name):
* dirtrack.el (shell-prefixed-directory-name, shell-process-cd):
* generic-x.el (comint-mode, comint-exec):
* image-dired.el (widget-forward):
* info.el (speedbar-add-expansion-list, speedbar-center-buffer-smartly)
(speedbar-change-expand-button-char)
(speedbar-change-initial-expansion-list, speedbar-delete-subblock)
(speedbar-make-specialized-keymap, speedbar-make-tag-line):
* printing.el (easy-menu-add-item, easy-menu-remove-item)
(widget-field-action, widget-value-set):
* speedbar.el (imenu--make-index-alist):
* term.el (ring-empty-p, ring-ref, ring-insert-at-beginning)
(ring-length, ring-insert):
* vcursor.el (compare-windows-skip-whitespace):
* woman.el (dired-get-filename):
Declare functions.
* term/w32-win.el (cygwin-convert-path-from-windows): Fix declaration.
Jay Belanger [Sat, 17 Nov 2012 21:34:09 +0000 (15:34 -0600)]
* calc/calc-forms.el (calc-gregorian-switch): Declare.
Jay Belanger [Sat, 17 Nov 2012 21:30:43 +0000 (15:30 -0600)]
* calc/calc.el (calc-gregorian-switch): New variable.
* calc/calc-forms.el (math-day-in-year, math-dt-before-p)
(math-absolute-from-gregorian-dt, math-absolute-from-julian-dt)
(math-date-to-julian-dt, math-date-to-gregorian-dt): New functions.
(math-leap-year-p): Add option to distinguish between Julian
and Gregorian calendars.
(math-day-number): Use `math-day-in-year' to do the computations.
(math-absolute-from-dt): Rename from `math-absolute-from-date'.
Use `math-absolute-from-gregorian' and `math-absolute-from-julian'
to do the computations.
(math-date-to-dt): Use `math-date-to-julian-dt' and `math-date-to-gregorian-dt'
to do the computations.
(calcFunc-weekday, math-format-date-part): Use the new version of the DATE to
determine the weekday.
(calcFunc-newmonth, calcFunc-newyear): Use `calc-gregorian-switch' when necessary.
Eli Zaretskii [Sat, 17 Nov 2012 20:41:21 +0000 (22:41 +0200)]
Fix bug #12914 with drag-n-drop in native MS-Windows build.
lisp/term/w32-win.el (w32-handle-dropped-file): Use 'file://' only on
Cygwin; otherwise use 'file:'.
(cygwin-convert-path-from-windows): Declare, to avoid
byte-compiler warnings.
Glenn Morris [Sat, 17 Nov 2012 19:01:09 +0000 (11:01 -0800)]
Relocate NEWS entry to correct section
Eli Zaretskii [Sat, 17 Nov 2012 18:51:06 +0000 (20:51 +0200)]
Fix bug #12878 with compilation failure with Visual C++ 11.0.
src/w32select.c: Include w32common.h before w32term.h, so that
windows.h gets included before w32term.h uses some of its
features, see below.
src/w32term.h (LOCALE_ENUMPROCA, LOCALE_ENUMPROCW) [_MSC_VER]: New
typedefs.
(EnumSystemLocalesA, EnumSystemLocalesW) [_MSC_VER]: New
prototypes.
(EnumSystemLocales) [_MSC_VER]: Define if undefined.
Paul Eggert [Sat, 17 Nov 2012 18:30:16 +0000 (10:30 -0800)]
Update comment to match recent change.
Eli Zaretskii [Sat, 17 Nov 2012 16:52:48 +0000 (18:52 +0200)]
Fix MS-Windows emulation of 'faccessat' wrt directories.
src/w32.c (faccessat): Pretend that directories have the execute bit
set. Emacs expects that, e.g., in files.el:cd-absolute.
Eli Zaretskii [Sat, 17 Nov 2012 16:46:45 +0000 (18:46 +0200)]
Fix bug #12829 with aborts on MS-Windows when several child processes die.
nt/inc/sys/wait.h: New file, with prototype of waitpid and
definitions of macros it needs.
nt/inc/ms-w32.h (wait): Don't define, 'wait' is not used anymore.
(sys_wait): Remove prototype.
nt/config.nt (HAVE_SYS_WAIT_H): Define to 1.
src/w32proc.c (create_child): Don't clip the PID of the child
process to fit into an Emacs integer, as this is no longer a
restriction.
(waitpid): Rename from sys_wait. Emulate a Posix 'waitpid' by
reaping only the process specified by PID argument, if that is
positive. Use PID instead of dead_child to know which process to
reap. Wait for the child to die only if WNOHANG is not in
OPTIONS.
(sys_select): Don't set dead_child.
src/sysdep.c (wait_for_termination_1): Remove the WINDOWSNT portion,
as it is no longer needed.
src/process.c (waitpid, WUNTRACED) [!WNOHANG]: Remove definitions,
no longer needed.
(record_child_status_change): Remove the setting of
record_at_most_one_child for the !WNOHANG case.
Jan Djärv [Sat, 17 Nov 2012 15:28:56 +0000 (16:28 +0100)]
* nsterm.m (hold_event): Set send_appdefined to YES.
(ns_select): Return at once if events are held (Bug#12834).
Paul Eggert [Sat, 17 Nov 2012 15:15:49 +0000 (07:15 -0800)]
Fix problems in ns port found by static checking.
* nsterm.m: Include <pthread.h>, for pthread_mutex_lock etc.
(hold_event, setPosition:portion:whole:): Send SIGIO only to self,
not to process group.
(ns_select): Use emacs_write, not write, as that's more robust
in the presence of signals.
(fd_handler:): Check for read errors.
Glenn Morris [Sat, 17 Nov 2012 11:20:58 +0000 (06:20 -0500)]
Auto-commit of loaddefs files.