Merge from trunk

This commit is contained in:
Daniel Colascione 2012-09-17 04:07:36 -08:00
commit 2ab329f3b5
392 changed files with 8367 additions and 6549 deletions

142
ChangeLog
View file

@ -1,3 +1,145 @@
2012-09-17 Paul Eggert <eggert@cs.ucla.edu>
Remove no-longer-needed Solaris 2.4 vfork bug workaround.
* configure.ac (ac_cv_func_vfork_works): Default to 'no' on
Solaris 2.4, so that AC_FUNC_VFORK doesn't think vfork works.
2012-09-17 Glenn Morris <rgm@gnu.org>
* configure.ac (copyright): New output variable.
(COPYRIGHT): New AC_DEFINE.
2012-09-16 Paul Eggert <eggert@cs.ucla.edu>
Remove configure's --without-sync-input option (Bug#12450).
* configure.ac (SYNC_INPUT, BROKEN_SA_RESTART): Remove.
2012-09-16 Glenn Morris <rgm@gnu.org>
Increase compartmentalization of Nextstep builds rules,
and store Emacs version number in fewer versioned files.
* configure.ac (ns_appsrc): Use relative names.
(ns_frag): Remove.
(Info-gnustep.plist, Emacs.desktop, Info.plist, InfoPlist.strings)
(nextstep/Makefile): Generate these nextstep files.
(SUBDIR_MAKEFILES): Add nextstep.
* Makefile.in (clean, distclean, bootstrap-clean): Add nextstep.
* make-dist (nextstep/templates): Add directory.
(nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj): Remove.
(nextstep/Cocoa/Emacs.base/Contents)
(nextstep, nextstep/GNUstep/Emacs.base/Resources): Update contents.
2012-09-15 Paul Eggert <eggert@cs.ucla.edu>
Port better to POSIX hosts lacking _setjmp (Bug#12446).
* configure.ac (HAVE__SETJMP, HAVE_SIGSETJMP): New symbols.
(_setjmp, _longjmp): Remove.
2012-09-14 Paul Eggert <eggert@cs.ucla.edu>
* configure.ac (--without-sync-input): Fix typo in usage message.
* configure.ac: Port to hosts lacking gtk.
(PKG_CHECK_MODULES): Capture pkg-config diagnostics
better, in particular, problems in invoking pkg-config itself.
This is useful on hosts that don't have pkg-config.
(GTK_MODULES): Do not exit 'configure' simply because gtk3
and gtk2 are both missing. Problem found on Solaris 8.
2012-09-13 Jan Djärv <jan.h.d@swipnet.se>
* configure.ac: Reorder Xaw3d messages.
Report Gtk+ 3 as GTK.
2012-09-13 Paul Eggert <eggert@cs.ucla.edu>
Simplify SIGIO usage (Bug#12408).
* configure.ac (NO_TERMIO, BROKEN_FIONREAD, BROKEN_SIGAIO)
(BROKEN_SIGPOLL, BROKEN_SIGPTY): Remove.
(USABLE_FIONREAD, USABLE_SIGIO): New symbols. All uses of
'defined SIGIO' replaced with 'defined USABLE_SIGIO', with no need
to #undef SIGIO now (which was error-prone). Likewise, all uses
of 'defined FIONREAD' replaced with 'defined USABLE_FIONREAD'.
2012-09-12 Jan Djärv <jan.h.d@swipnet.se>
* configure.ac: No --with-x-toolkit given: Try gtk3 toolkit first
and then gtk2 if not found.
--with-x-toolkit=gtk|yes: As above, but fail if gtk2 or gt3 not found.
--with-x-toolkit=gtk2: Only try gtk2, fail if not found.
--with-x-toolkit=gtk3: Only try gtk3, fail if not found.
2012-09-11 Glenn Morris <rgm@gnu.org>
* Makefile.in (install-arch-dep, install-arch-indep, install-doc):
Be more explicit about dependencies, for parallel `make install'.
2012-09-11 Paul Eggert <eggert@cs.ucla.edu>
Simplify, document, and port floating-point (Bug#12381).
* configure.ac (logb, cbrt): Do not check for these functions,
as they are not being used.
2012-09-10 Paul Eggert <eggert@cs.ucla.edu>
Improve robustness of 'make bootstrap' (Bug#12376).
Run autogen.sh after bootstrap-clean, to avoid bzr pull issues.
* INSTALL, README: Document autogen.sh.
* Makefile.in (Makefile): Mark it as precious, since it's updated
atomically.
(MAKE_CONFIG_STATUS): New macro.
(config.status, bootstrap): Use it. This causes 'make bootstrap'
to run config.status with the --recheck option, which is more
appropriate for a bootstrap.
(bootstrap): Run autogen.sh right after cleaning. Don't worry
about failures due to missing tools.
* autogen.sh: Exit with status 101 when failing due to missing tools.
* make-dist: Distribute autogen.sh.
2012-09-09 Paul Eggert <eggert@cs.ucla.edu>
Assume C89 or later for math functions (Bug#12381).
* configure.ac (frexp, fmod): Remove checks for these functions,
as we now assume them.
(FLOAT_CHECK_DOMAIN, HAVE_INVERSE_HYPERBOLIC, NO_MATHERR)
(HAVE_EXCEPTION):
Remove; no longer needed.
2012-09-07 Paul Eggert <eggert@cs.ucla.edu>
More signal-handler cleanup (Bug#12327).
* configure.ac (FLOAT_CHECK_DOMAIN): Comment fix (Bug#12327).
2012-09-06 Paul Eggert <eggert@cs.ucla.edu>
Signal-handler cleanup (Bug#12327).
* configure.ac (PTY_OPEN, PTY_TTY_NAME_SPRINTF):
Adjust to syssignal.h changes.
(SIGNAL_H_AB): Remove; no longer needed.
2012-09-04 Paul Eggert <eggert@cs.ucla.edu>
Simplify redefinition of 'abort' (Bug#12316).
* configure.ac (NO_ABRT): Remove.
* configure.ac (_setjmp, _longjmp): Check by compiling
instead of by guessing. The guesses were wrong for
recent versions of Solaris, such as Solaris 11.
2012-09-03 Paul Eggert <eggert@cs.ucla.edu>
* configure.ac (WARN_CFLAGS): Omit -Wjump-misses-init.
It generates false alarms in doc.c, regex.c, xdisp.c. See
<http://lists.gnu.org/archive/html/emacs-devel/2012-09/msg00040.html>.
Merge from gnulib, incorporating:
2012-08-29 stdbool: be more compatible with mixed C/C++ compiles
2011-11-30 manywarnings: update the list of "all" warnings
2012-09-02 Jan Djärv <jan.h.d@swipnet.se>
* configure.ac (HAVE_GOBJECT): Check for gobject-2.0 (Bug#12332).
2012-09-01 Paul Eggert <eggert@cs.ucla.edu>
* configure.ac (_FORTIFY_SOURCE): Define only when optimizing.

View file

@ -695,9 +695,9 @@ running the `configure' program, you have to perform the following steps.
corresponding `Makefile.in' files. This isn't so hard, just a matter
of editing in appropriate substitutions for the @...@ constructs.
The `configure' script is built from `configure.ac' by the `autoconf'
program. You need at least the version of autoconf specified in the
AC_PREREQ(...) command to rebuild `configure' from `configure.ac'.
The `configure' script is built from `configure.ac' by the
`autogen.sh' script, which checks that `autoconf' and other build
tools are sufficiently up to date and then runs the build tools.
BUILDING GNU EMACS BY HAND

View file

@ -360,15 +360,17 @@ $(MAKEFILE_NAME): config.status $(srcdir)/src/config.in \
$(srcdir)/Makefile.in $(SUBDIR_MAKEFILES_IN)
./config.status
# Don't erase config.status if make is interrupted while refreshing it.
.PRECIOUS: config.status
# Don't erase these files if make is interrupted while refreshing them.
.PRECIOUS: Makefile config.status
config.status: ${srcdir}/configure ${srcdir}/lisp/version.el
MAKE_CONFIG_STATUS = \
if [ -x ./config.status ]; then \
./config.status --recheck; \
else \
./configure $(CONFIGURE_FLAGS); \
fi
config.status: ${srcdir}/configure ${srcdir}/lisp/version.el
$(MAKE_CONFIG_STATUS)
AUTOCONF_INPUTS = $(srcdir)/configure.ac $(srcdir)/aclocal.m4
@ -383,6 +385,10 @@ AUTOMAKE_INPUTS = $(srcdir)/aclocal.m4 $(srcdir)/lib/Makefile.am \
$(srcdir)/lib/gnulib.mk
$(srcdir)/lib/Makefile.in: $(AUTOMAKE_INPUTS)
cd $(srcdir) && automake --gnu -a -c lib/Makefile
# Regenerate files that this makefile would have made, if this makefile
# had been built by Automake. The name 'am--refresh' is for
# compatibility with subsidiary Automake-generated makefiles.
am--refresh: $(srcdir)/aclocal.m4 $(srcdir)/configure $(srcdir)/src/config.in
.PHONY: am--refresh
@ -427,7 +433,7 @@ write_subdir=if [ -f $${subdir}/subdirs.el ]; \
### Install the executables that were compiled specifically for this machine.
### We do install-arch-indep first because the executable needs the
### Lisp files and DOC file to work properly.
install-arch-dep: install-arch-indep install-doc
install-arch-dep: src install-arch-indep install-doc
umask 022; ${MKDIR_P} $(DESTDIR)${bindir}
cd lib-src && \
$(MAKE) install $(MFLAGS) prefix=${prefix} \
@ -496,7 +502,7 @@ set_installuser=for installuser in $${LOGNAME} $${USERNAME} $${USER} \
## work correctly, and therefore no idea when tar can be replaced.
## See also these comments from 2004 about cp -r working fine:
## http://lists.gnu.org/archive/html/autoconf-patches/2004-11/msg00005.html
install-arch-indep: install-info install-man ${INSTALL_ARCH_INDEP_EXTRA}
install-arch-indep: lisp leim install-info install-man ${INSTALL_ARCH_INDEP_EXTRA}
umask 022 ; \
locallisppath='${locallisppath}'; \
IFS=:; \
@ -567,7 +573,7 @@ install-arch-indep: install-info install-man ${INSTALL_ARCH_INDEP_EXTRA}
## Note that install-arch-indep deletes and recreates the entire
## installed etc/ directory, so we need it to run before this does.
install-doc: install-arch-indep
install-doc: src install-arch-indep
-unset CDPATH; \
umask 022; ${MKDIR_P} $(DESTDIR)${docdir} ; \
if [ `cd ./etc; /bin/pwd` != `cd $(DESTDIR)${docdir}; /bin/pwd` ]; \
@ -731,6 +737,7 @@ clean: FRC
-(cd doc/lispref && $(MAKE) $(MFLAGS) clean)
-(cd doc/lispintro && $(MAKE) $(MFLAGS) clean)
(cd leim; $(MAKE) $(MFLAGS) clean)
(cd nextstep && $(MAKE) $(MFLAGS) clean)
### `bootclean'
### Delete all files that need to be remade for a clean bootstrap.
@ -757,6 +764,7 @@ distclean: FRC
(cd doc/lispintro && $(MAKE) $(MFLAGS) distclean)
(cd leim; $(MAKE) $(MFLAGS) distclean)
(cd lisp; $(MAKE) $(MFLAGS) distclean)
(cd nextstep && $(MAKE) $(MFLAGS) distclean)
${top_distclean}
### `bootstrap-clean'
@ -774,10 +782,9 @@ bootstrap-clean: FRC
-(cd doc/lispintro && $(MAKE) $(MFLAGS) maintainer-clean)
(cd leim; $(MAKE) $(MFLAGS) maintainer-clean)
(cd lisp; $(MAKE) $(MFLAGS) bootstrap-clean)
(cd nextstep && $(MAKE) $(MFLAGS) maintainer-clean)
[ ! -f config.log ] || mv -f config.log config.log~
${top_bootclean}
## configure; make bootstrap replaces the real config.log from configure
## with the truncated one from config.status. The former is more useful.
### `maintainer-clean'
### Delete everything from the current directory that can be
@ -883,14 +890,14 @@ dvi:
.PHONY: bootstrap
## configure; make bootstrap replaces the real config.log from configure
## with the truncated one from config.status. The former is more useful.
# Bootstrapping does the following:
# * Remove files to start from a clean slate.
# * Run autogen.sh, but don't worry about exit status 101 (missing tools).
# * Build Makefile, to build the build procedure itself.
# * Do the actual build.
bootstrap: bootstrap-clean FRC
if [ -x ./config.status ]; then \
./config.status; \
else \
./configure $(CONFIGURE_FLAGS); \
fi
cd $(srcdir) && { ./autogen.sh || test $$? -eq 101; }
$(MAKE_CONFIG_STATUS)
$(MAKE) $(MFLAGS) info all
.PHONY: check-declare

11
README
View file

@ -41,9 +41,14 @@ The file `configure.ac' is the input used by the autoconf program to
construct the `configure' script. Since Emacs has some configuration
requirements that autoconf can't meet directly, and for historical
reasons, `configure.ac' uses an unholy marriage of custom-baked
configuration code and autoconf macros. If you want to rebuild
`configure' from `configure.ac', you will need to install a recent
version of autoconf and GNU m4.
configuration code and autoconf macros.
The shell script `autogen.sh' generates 'configure' and other files by
running the GNU build tools autoconf and automake, which in turn use
GNU m4 and Perl. If you want to use it, you will need to install
recent versions of these build tools. This should be needed only if
you edit files like `configure.ac' that specify Emacs's autobuild
procedure.
The file `Makefile.in' is a template used by `configure' to create
`Makefile'.

View file

@ -90,11 +90,6 @@ BROKEN_GETWD
BROKEN_GET_CURRENT_DIR_NAME
BROKEN_NON_BLOCKING_CONNECT
BROKEN_PTY_READ_AFTER_EAGAIN
BROKEN_SA_RESTART
BROKEN_SIGAIO
BROKEN_SIGIO
BROKEN_SIGPOLL
BROKEN_SIGPTY
CLASH_DETECTION
DATA_SEG_BITS
DATA_START
@ -107,7 +102,6 @@ EMACS_CONFIGURATION
EMACS_CONFIG_OPTIONS
EMACS_INT
EMACS_UINT
FLOAT_CHECK_DOMAIN
GC_MARK_SECONDARY_STACK
GC_MARK_STACK
GC_SETJMP_WORKS
@ -121,7 +115,6 @@ HAVE_ATTRIBUTE_ALIGNED
HAVE_BDFFONT
HAVE_BOXES
HAVE_C99_STRTOLD
HAVE_CBRT
HAVE_CFMAKERAW
HAVE_CFSETSPEED
HAVE_CLOCK_GETTIME
@ -158,12 +151,10 @@ HAVE_ENDPWENT
HAVE_ENVIRON_DECL
HAVE_EUIDACCESS
HAVE_FCNTL_H
HAVE_FMOD
HAVE_FORK
HAVE_FPATHCONF
HAVE_FREEIFADDRS
HAVE_FREETYPE
HAVE_FREXP
HAVE_FSEEKO
HAVE_FSYNC
HAVE_FUTIMENS
@ -217,7 +208,6 @@ HAVE_IFADDRS_H
HAVE_IMAGEMAGICK
HAVE_INET_SOCKETS
HAVE_INTTYPES_H
HAVE_INVERSE_HYPERBOLIC
HAVE_JPEG
HAVE_KERBEROSIV_DES_H
HAVE_KERBEROSIV_KRB_H
@ -255,7 +245,6 @@ HAVE_LIBXMU
HAVE_LINUX_VERSION_H
HAVE_LOCALTIME_R
HAVE_LOCAL_SOCKETS
HAVE_LOGB
HAVE_LONG_FILE_NAMES
HAVE_LONG_LONG_INT
HAVE_LRAND48
@ -428,10 +417,7 @@ MAIL_USE_POP
MAIL_USE_SYSTEM_LOCK
MAXPATHLEN
NLIST_STRUCT
NO_ABORT
NO_EDITRES
NO_MATHERR
NO_TERMIO
NSIG
NSIG_MINIMUM
NULL_DEVICE
@ -447,7 +433,6 @@ PTY_OPEN
PTY_TTY_NAME_SPRINTF
PURESIZE
RUN_TIME_REMAP
SA_RESTART
SETPGRP_RELEASES_CTTY
SETUP_SLAVE_PTY
SIGALRM
@ -580,7 +565,6 @@ getpid
isatty
kill
link
logb
lseek
mkdir
mktemp
@ -622,7 +606,6 @@ fopen
getpid
index
isatty
logb
lseek
mkdir
mktemp

View file

@ -1,3 +1,49 @@
2012-09-17 Glenn Morris <rgm@gnu.org>
* admin.el (add-log-time-format): Declare.
* admin.el (cusver-scan, cusver-check): Bind local variables.
* admin.el (set-version): Set major version in
etc/refcards/ru-refcard.tex and etc/refcards/emacsver.tex.
(set-copyright): In etc/refcards, only change ru-refcard.tex
and emacsver.tex.
* admin.el (set-copyright): No more need to set copyrights for
nextstep, or .c files. Add configure.ac and config.nt.
2012-09-16 Paul Eggert <eggert@cs.ucla.edu>
Remove configure's --without-sync-input option (Bug#12450).
* CPP-DEFINES (BROKEN_SA_RESTART, SA_RESTART): Remove.
2012-09-16 Glenn Morris <rgm@gnu.org>
* admin.el (set-version): No more need to set nextstep versions.
(set-copyright): Update for moved nextstep files.
2012-09-13 Paul Eggert <eggert@cs.ucla.edu>
Simplify SIGIO usage (Bug#12408).
* CPP_DEFINES (BROKEN_SIGAIO, BROKEN_SIGIO, BROKEN_SIGPOLL)
(BROKEN_SIGPTY, NO_TERMIO): Remove.
2012-09-11 Paul Eggert <eggert@cs.ucla.edu>
Simplify, document, and port floating-point (Bug#12381).
* CPP-DEFINES (HAVE_CBRT, HAVE_LOGB, logb): Remove.
2012-09-09 Paul Eggert <eggert@cs.ucla.edu>
Assume C89 or later for math functions (Bug#12381).
* CPP-DEFINES (HAVE_FMOD, HAVE_FREXP, FLOAT_CHECK_DOMAIN)
(HAVE_INVERSE_HYPERBOLIC, NO_MATHERR): Remove.
2012-09-04 Paul Eggert <eggert@cs.ucla.edu>
Simplify redefinition of 'abort' (Bug#12316).
* CPP-DEFINES (NO_ABORT): Remove.
2012-08-28 Glenn Morris <rgm@gnu.org>
* bzrmerge.el (bzrmerge-merges): Allow unversioned files in the tree.

View file

@ -26,6 +26,8 @@
;;; Code:
(defvar add-log-time-format) ; in add-log
(defun add-release-logs (root version)
"Add \"Version VERSION released.\" change log entries in ROOT.
Root must be the root of an Emacs source tree."
@ -126,39 +128,16 @@ Root must be the root of an Emacs source tree."
(set-version-in-file root "nt/emacsclient.rc" comma-space-version
(rx (and "\"ProductVersion\"" (0+ space) ?,
(0+ space) ?\" (submatch (1+ (in "0-9, ")))
"\\0\""))))
;; nextstep.
(set-version-in-file
root "nextstep/Cocoa/Emacs.base/Contents/Info.plist"
version (rx (and "CFBundleGetInfoString" (1+ anything) "Emacs" (1+ space)
(submatch (1+ (in "0-9."))))))
(set-version-in-file
root "nextstep/Cocoa/Emacs.base/Contents/Info.plist"
version (rx (and "CFBundleShortVersionString" (1+ not-newline) ?\n
(0+ not-newline) "<string>" (0+ space)
(submatch (1+ (in "0-9."))))))
(set-version-in-file
root "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings"
version (rx (and "CFBundleShortVersionString" (0+ space) ?= (0+ space)
?\" (0+ space) "Version" (1+ space)
(submatch (1+ (in "0-9."))))))
(set-version-in-file
root "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings"
version (rx (and "CFBundleGetInfoString" (0+ space) ?= (0+ space)
?\" (0+ space) "Emacs version" (1+ space)
(submatch (1+ (in "0-9."))))))
(set-version-in-file
root "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist"
version (rx (and "ApplicationRelease" (0+ space) ?= (0+ space)
?\" (0+ space) (submatch (1+ (in "0-9."))))))
(set-version-in-file
root "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist"
version (rx (and "FullVersionID" (0+ space) ?= (0+ space)
?\" (0+ space) "Emacs" (1+ space)
(submatch (1+ (in "0-9."))))))
(set-version-in-file
root "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop"
version (rx (and "Version=" (submatch (1+ (in "0-9.")))))))
"\\0\"")))
(when (string-match "\\([0-9]\\{2,\\}\\)" version)
(setq version (match-string 1 version))
(set-version-in-file root "etc/refcards/ru-refcard.tex" version
"\\\\newcommand{\\\\versionemacs}\\[0\\]\
{\\([0-9]\\{2,\\}\\)}.+%.+version of Emacs")
(set-version-in-file root "etc/refcards/emacsver.tex" version
"\\\\def\\\\versionemacs\
{\\([0-9]\\{2,\\}\\)}.+%.+version of Emacs"))))
;; Note this makes some assumptions about form of short copyright.
(defun set-copyright (root copyright)
@ -172,45 +151,24 @@ Root must be the root of an Emacs source tree."
(format-time-string "%Y")))))
(unless (file-exists-p (expand-file-name "src/emacs.c" root))
(error "%s doesn't seem to be the root of an Emacs source tree" root))
(set-version-in-file root "src/emacs.c" copyright
(rx (and "emacs_copyright" (0+ (not (in ?\")))
?\" (submatch (1+ (not (in ?\")))) ?\")))
(set-version-in-file root "lib-src/ebrowse.c" copyright
(rx (and "emacs_copyright" (0+ (not (in ?\")))
?\" (submatch (1+ (not (in ?\")))) ?\")))
(set-version-in-file root "lib-src/etags.c" copyright
(rx (and "emacs_copyright" (0+ (not (in ?\")))
(set-version-in-file root "configure.ac" copyright
(rx (and bol "copyright" (0+ (not (in ?\")))
?\" (submatch (1+ (not (in ?\")))) ?\")))
(set-version-in-file root "nt/config.nt" copyright
(rx (and bol "#" (0+ blank) "define" (1+ blank)
"COPYRIGHT" (1+ blank)
?\" (submatch (1+ (not (in ?\")))) ?\")))
(set-version-in-file root "lib-src/rcs2log" copyright
(rx (and "Copyright" (0+ space) ?= (0+ space)
?\' (submatch (1+ nonl)))))
;; This one is a nuisance, as it needs to be split over two lines.
(string-match "\\(.*[0-9]\\{4\\} *\\)\\(.*\\)" copyright)
;; nextstep.
(set-version-in-file
root "nextstep/Cocoa/Emacs.base/Contents/Info.plist"
copyright (rx (and "CFBundleGetInfoString" (1+ anything) "Emacs" (1+ space)
(1+ (in "0-9.")) (1+ space)
(submatch (1+ (not (in ?\<)))))))
(set-version-in-file
root "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings"
copyright (rx (and "NSHumanReadableCopyright" (0+ space) ?\= (0+ space)
?\" (submatch (1+ (not (in ?\")))))))
(set-version-in-file
root "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist"
copyright (rx (and "Copyright" (0+ space) ?\= (0+ space)
?\" (submatch (1+ (not (in ?\")))))))
(when (string-match "\\([0-9]\\{4\\}\\)" copyright)
(setq copyright (match-string 1 copyright))
(dolist (file (directory-files (expand-file-name "etc/refcards" root)
t "\\.tex\\'"))
(unless (string-match "gnus-refcard\\.tex" file)
(set-version-in-file
root file copyright
(concat (if (string-match "ru-refcard\\.tex" file)
"\\\\newcommand{\\\\cyear}\\[0\\]{"
"\\\\def\\\\year{")
"\\([0-9]\\{4\\}\\)}.+%.+copyright year"))))))
(set-version-in-file root "etc/refcards/ru-refcard.tex" copyright
"\\\\newcommand{\\\\cyear}\\[0\\]\
{\\([0-9]\\{4\\}\\)}.+%.+copyright year")
(set-version-in-file root "etc/refcards/emacsver.tex" copyright
"\\\\def\\\\year\
{\\([0-9]\\{4\\}\\)}.+%.+copyright year")))
;;; Various bits of magic for generating the web manuals
@ -459,7 +417,7 @@ Also generate PostScript output in PS-DEST."
(setq done t))
(t
(if (eobp)
(error "Parse error in %s" f))
(error "Parse error in %s" f)) ; f is bound in manual-html-node
(unless open-td
(setq done t))))
(forward-line 1))))
@ -491,7 +449,7 @@ If optional argument OLD is non-nil, also scan for defvars."
(let ((m (format "Scanning %s..." file))
(re (format "^[ \t]*\\((def%s\\)[ \t\n]"
(if old "\\(?:custom\\|var\\)" "custom")))
alist var ver)
alist var ver form)
(message "%s" m)
(with-temp-buffer
(insert-file-contents file)
@ -550,7 +508,7 @@ changes (in a non-trivial way). This function does not check for that."
(mapcar
(lambda (file)
(cons file (cusver-scan file))) newfiles)))
oldcus result thisfile)
oldcus result thisfile file)
(message "Reading old defcustoms...")
(dolist (file oldfiles)
(setq oldcus (append oldcus (cusver-scan file t))))

View file

@ -618,6 +618,16 @@ mv /var/lib/mailman/spam/not-really-spam.msg /var/lib/mailman/not-spam/
Also check that the sender was not added to the auto-discard/reject list
in the debbugs-submit Mailman interface.
If you don't have the actual mail, just the mailman moderation mail
version of it, you need to extract the original mail, and add the
following headers:
1) The leading envelope From line.
2) Message-ID (get it from /var/log/mailman/vette).
3) X-Debbugs-Envelope-To: submit
Then pipe it to receive as above.
** Administrivia
The debbugs-submit list should have the administrivia option off,

View file

@ -201,7 +201,7 @@ This is not recommended - see the comments in \`copy_autogen'.
Please report any problems with this script to bug-gnu-emacs@gnu.org .
EOF
exit 1
exit 101 # Exit status 101 means tools were missing.
fi
echo "Your system has the required tools, running autoreconf..."

View file

@ -359,6 +359,8 @@ GNULIB_WRITE = @GNULIB_WRITE@
GNULIB__EXIT = @GNULIB__EXIT@
GNUSTEP_CFLAGS = @GNUSTEP_CFLAGS@
GNU_OBJC_CFLAGS = @GNU_OBJC_CFLAGS@
GOBJECT_CFLAGS = @GOBJECT_CFLAGS@
GOBJECT_LIBS = @GOBJECT_LIBS@
GREP = @GREP@
GSETTINGS_CFLAGS = @GSETTINGS_CFLAGS@
GSETTINGS_LIBS = @GSETTINGS_LIBS@
@ -785,6 +787,7 @@ builddir = @builddir@
cache_file = @cache_file@
canonical = @canonical@
configuration = @configuration@
copyright = @copyright@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@

View file

@ -50,9 +50,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to the number of bits in type 'wint_t'. */
#undef BITSIZEOF_WINT_T
/* Define if FIONREAD should not be used. */
#undef BROKEN_FIONREAD
/* Define if getwd should not be used. */
#undef BROKEN_GETWD
@ -62,21 +59,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define on FreeBSD to work around an issue when reading from a PTY. */
#undef BROKEN_PTY_READ_AFTER_EAGAIN
/* Define if SA_RESTART should only be used in batch mode. */
#undef BROKEN_SA_RESTART
/* Define if SIGAIO should not be used. */
#undef BROKEN_SIGAIO
/* Define if SIGIO should not be used. */
#undef BROKEN_SIGIO
/* Define if SIGPOLL should not be used. */
#undef BROKEN_SIGPOLL
/* Define if SIGPTY should not be used. */
#undef BROKEN_SIGPTY
/* Define if the system is compatible with BSD 4.2. */
#undef BSD4_2
@ -97,6 +79,9 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
his/her Emacs. */
#undef CLASH_DETECTION
/* Short copyright string for this version of Emacs. */
#undef COPYRIGHT
/* Define to one of '_getb67', 'GETB67', 'getb67' for Cray-2 and Cray-YMP
systems. This function is required for 'alloca.c' support on those systems.
*/
@ -157,10 +142,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
*/
#undef FIRST_PTY_LETTER
/* Define if the float library doesn't handle errors by either setting errno,
or signaling SIGFPE/SIGILL. */
#undef FLOAT_CHECK_DOMAIN
/* Enable compile-time and run-time bounds-checking, and some warnings,
without upsetting glibc 2.15+. */
#if defined __OPTIMIZE__ && __OPTIMIZE__
@ -250,9 +231,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 if strtold conforms to C99. */
#undef HAVE_C99_STRTOLD
/* Define to 1 if you have the `cbrt' function. */
#undef HAVE_CBRT
/* Define to 1 if you have the `cfmakeraw' function. */
#undef HAVE_CFMAKERAW
@ -371,9 +349,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 if you have the <fcntl.h> header file. */
#undef HAVE_FCNTL_H
/* Define to 1 if you have the `fmod' function. */
#undef HAVE_FMOD
/* Define to 1 if you have the `fork' function. */
#undef HAVE_FORK
@ -386,9 +361,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 if using the freetype and fontconfig libraries. */
#undef HAVE_FREETYPE
/* Define to 1 if you have the `frexp' function. */
#undef HAVE_FREXP
/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */
#undef HAVE_FSEEKO
@ -540,9 +512,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define if you have the functions acosh, asinh, and atanh. */
#undef HAVE_INVERSE_HYPERBOLIC
/* Define to 1 if you have the jpeg library (-ljpeg). */
#undef HAVE_JPEG
@ -651,9 +620,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 if you have the `localtime_r' function. */
#undef HAVE_LOCALTIME_R
/* Define to 1 if you have the `logb' function. */
#undef HAVE_LOGB
/* Define to 1 if you support file names longer than 14 characters. */
#undef HAVE_LONG_FILE_NAMES
@ -825,6 +791,10 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 if 'wint_t' is a signed integer type. */
#undef HAVE_SIGNED_WINT_T
/* Define to 1 if sigsetjmp and siglongjmp work. The value of this symbol is
irrelevant if HAVE__SETJMP is defined. */
#undef HAVE_SIGSETJMP
/* Define to 1 if the system has the type `sigset_t'. */
#undef HAVE_SIGSET_T
@ -1108,6 +1078,9 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 if you have the `_ftime' function. */
#undef HAVE__FTIME
/* Define to 1 if _setjmp and _longjmp work. */
#undef HAVE__SETJMP
/* Define to 1 if you have the `__builtin_unwind_init' function. */
#undef HAVE___BUILTIN_UNWIND_INIT
@ -1179,21 +1152,12 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
`NO'. */
#undef NARROWPROTO
/* Do not define abort in emacs.c. */
#undef NO_ABORT
/* Define if XEditRes should not be used. */
#undef NO_EDITRES
/* Define to 1 if you don't have struct exception in math.h. */
#undef NO_MATHERR
/* Define to 1 if your C compiler doesn't accept -c and -o together. */
#undef NO_MINUS_C_MINUS_O
/* Define if termio.h should not be included. */
#undef NO_TERMIO
/* Minimum value of NSIG. */
#undef NSIG_MINIMUM
@ -1303,9 +1267,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Make process_send_signal work by "typing" a signal character on the pty. */
#undef SIGNALS_VIA_CHARACTERS
/* Define if AH_BOTTOM should include signal.h. */
#undef SIGNAL_H_AHB
/* Define to l, ll, u, ul, ull, etc., as suitable for constants of type
'sig_atomic_t'. */
#undef SIG_ATOMIC_T_SUFFIX
@ -1334,9 +1295,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define to 1 on System V Release 4. */
#undef SVR4
/* Process async input synchronously. */
#undef SYNC_INPUT
/* Define to use system malloc. */
#undef SYSTEM_MALLOC
@ -1381,6 +1339,12 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
/* Define if the system has Unix98 PTYs. */
#undef UNIX98_PTYS
/* Define to 1 if FIONREAD is usable. */
#undef USABLE_FIONREAD
/* Define to 1 if SIGIO is usable. */
#undef USABLE_SIGIO
/* How to get a user's full name. */
#undef USER_FULL_NAME
@ -1542,12 +1506,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
declarations. Define as empty for no equivalent. */
#undef __restrict_arr
/* Some platforms redefine this. */
#undef _longjmp
/* Some platforms redefine this. */
#undef _setjmp
/* Some platforms that do not use configure define this to include extra
configuration information. */
#undef config_opsysfile

643
autogen/configure vendored

File diff suppressed because it is too large Load diff

View file

@ -128,17 +128,12 @@ AC_ARG_WITH([mailhost],[AS_HELP_STRING([--with-mailhost=HOSTNAME],
OPTION_DEFAULT_ON([sound],[don't compile with sound support])
OPTION_DEFAULT_ON([sync-input],[process async input synchronously])
if test "$with_sync_input" = yes; then
AC_DEFINE(SYNC_INPUT, 1, [Process async input synchronously.])
fi
dnl FIXME currently it is not the last.
dnl This should be the last --with option, because --with-x is
dnl added later on when we find the path of X, and it's best to
dnl keep them together visually.
AC_ARG_WITH([x-toolkit],[AS_HELP_STRING([--with-x-toolkit=KIT],
[use an X toolkit (KIT one of: yes or gtk, gtk3, lucid or athena, motif, no)])],
[use an X toolkit (KIT one of: yes or gtk, gtk2, gtk3, lucid or athena, motif, no)])],
[ case "${withval}" in
y | ye | yes ) val=gtk ;;
n | no ) val=no ;;
@ -146,11 +141,13 @@ AC_ARG_WITH([x-toolkit],[AS_HELP_STRING([--with-x-toolkit=KIT],
a | at | ath | athe | athen | athena ) val=athena ;;
m | mo | mot | moti | motif ) val=motif ;;
g | gt | gtk ) val=gtk ;;
gtk2 ) val=gtk2 ;;
gtk3 ) val=gtk3 ;;
* )
AC_MSG_ERROR([`--with-x-toolkit=$withval' is invalid;
this option's value should be `yes', `no', `lucid', `athena', `motif', `gtk' or
`gtk3'. `yes' and `gtk' are synonyms. `athena' and `lucid' are synonyms.])
this option's value should be `yes', `no', `lucid', `athena', `motif', `gtk',
`gtk2' or `gtk3'. `yes' and `gtk' are synonyms.
`athena' and `lucid' are synonyms.])
;;
esac
with_x_toolkit=$val
@ -706,6 +703,7 @@ else
nw="$nw -Wswitch-default" # Too many warnings for now
nw="$nw -Wfloat-equal" # warns about high-quality code
nw="$nw -Winline" # OK to ignore 'inline'
nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
@ -1187,9 +1185,10 @@ AC_DEFUN([PKG_CHECK_MODULES], [
$1_CFLAGS=""
$1_LIBS=""
## If we have a custom action on failure, don't print errors, but
## do set a variable so people can do so.
$1_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
ifelse([$4], ,echo $$1_PKG_ERRORS,)
## do set a variable so people can do so. Do it in a subshell
## to capture any diagnostics in invoking pkg-config.
$1_PKG_ERRORS=`($PKG_CONFIG --print-errors "$2") 2>&1`
ifelse([$4], ,echo "$$1_PKG_ERRORS",)
fi
AC_SUBST($1_CFLAGS)
@ -1302,17 +1301,6 @@ if test $emacs_cv_speed_t = yes; then
[Define to 1 if `speed_t' is declared by <termios.h>.])
fi
AC_CACHE_CHECK(for struct exception, emacs_cv_struct_exception,
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <math.h>]],
[[static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;]])],
emacs_cv_struct_exception=yes, emacs_cv_struct_exception=no))
HAVE_EXCEPTION=$emacs_cv_struct_exception
dnl Define on Darwin so emacs symbols will not conflict with those
dnl in the System framework. Otherwise -prebind will not work.
if test $emacs_cv_struct_exception != yes || test $opsys = darwin; then
AC_DEFINE(NO_MATHERR, 1, [Define to 1 if you don't have struct exception in math.h.])
fi
AC_CHECK_HEADERS_ONCE(sys/socket.h)
AC_CHECK_HEADERS(net/if.h, , , [AC_INCLUDES_DEFAULT
#if HAVE_SYS_SOCKET_H
@ -1469,13 +1457,13 @@ if test "${with_ns}" != no; then
ns_appdir=`pwd`/nextstep/Emacs.app
ns_appbindir=${ns_appdir}/Contents/MacOS
ns_appresdir=${ns_appdir}/Contents/Resources
ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
ns_appsrc=Cocoa/Emacs.base
elif test -f $GNUSTEP_CONFIG_FILE; then
NS_IMPL_GNUSTEP=yes
ns_appdir=`pwd`/nextstep/Emacs.app
ns_appbindir=${ns_appdir}
ns_appresdir=${ns_appdir}/Resources
ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
ns_appsrc=GNUstep/Emacs.base
dnl FIXME sourcing this several times in subshells seems inefficient.
GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
@ -1530,7 +1518,6 @@ AC_SUBST(TEMACS_LDFLAGS2)
INSTALL_ARCH_INDEP_EXTRA=install-etc
ns_self_contained=no
ns_frag=/dev/null
NS_OBJ=
NS_OBJC_OBJ=
if test "${HAVE_NS}" = yes; then
@ -1557,7 +1544,6 @@ if test "${HAVE_NS}" = yes; then
leimdir="\${ns_appresdir}/leim"
INSTALL_ARCH_INDEP_EXTRA=
fi
ns_frag=$srcdir/src/ns.mk
NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
fi
CFLAGS="$tmp_CFLAGS"
@ -1567,7 +1553,6 @@ AC_SUBST(ns_self_contained)
AC_SUBST(NS_OBJ)
AC_SUBST(NS_OBJC_OBJ)
AC_SUBST(LIB_STANDARD)
AC_SUBST_FILE(ns_frag)
HAVE_W32=no
W32_OBJ=
@ -1614,6 +1599,9 @@ case "${window_system}" in
dnl Don't set this for GTK. A lot of tests below assumes Xt when
dnl USE_X_TOOLKIT is set.
USE_X_TOOLKIT=none ;;
gtk2 ) with_gtk2=yes
term_header=gtkutil.h
USE_X_TOOLKIT=none ;;
gtk3 ) with_gtk3=yes
term_header=gtkutil.h
USE_X_TOOLKIT=none ;;
@ -1939,35 +1927,41 @@ fi
HAVE_GTK=no
GTK_OBJ=
if test "${with_gtk3}" = "yes"; then
check_gtk2=no
gtk3_pkg_errors=
if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
GLIB_REQUIRED=2.28
GTK_REQUIRED=3.0
GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
dnl Checks for libraries.
PKG_CHECK_MODULES(GTK, $GTK_MODULES, pkg_check_gtk=yes, pkg_check_gtk=no)
if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
AC_MSG_ERROR($GTK_PKG_ERRORS)
fi
AC_DEFINE(HAVE_GTK3, 1, [Define to 1 if using GTK 3 or later.])
GTK_OBJ=emacsgtkfixed.o
term_header=gtkutil.h
if test "$pkg_check_gtk" = "yes"; then
AC_DEFINE(HAVE_GTK3, 1, [Define to 1 if using GTK 3 or later.])
GTK_OBJ=emacsgtkfixed.o
term_header=gtkutil.h
else
check_gtk2=yes
gtk3_pkg_errors="$GTK_PKG_ERRORS "
fi
fi
if test "$pkg_check_gtk" != "yes"; then
HAVE_GTK=no
if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
GLIB_REQUIRED=2.10
GTK_REQUIRED=2.10
GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
dnl Checks for libraries.
PKG_CHECK_MODULES(GTK, $GTK_MODULES, pkg_check_gtk=yes, pkg_check_gtk=no)
if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
AC_MSG_ERROR($GTK_PKG_ERRORS)
if test "$pkg_check_gtk" = "no" &&
{ test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
then
AC_MSG_ERROR($gtk3_pkg_errors$GTK_PKG_ERRORS)
fi
fi
fi
if test x"$pkg_check_gtk" = xyes; then
@ -2082,6 +2076,11 @@ if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
fi
if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
PKG_CHECK_MODULES(GOBJECT, gobject-2.0 >= 2.0, HAVE_GOBJECT=yes, HAVE_GOBJECT=no)
if test "$HAVE_GOBJECT" = "yes"; then
SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
fi
SAVE_CFLAGS="$CFLAGS"
SAVE_LIBS="$LIBS"
CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
@ -2132,7 +2131,6 @@ HAVE_XAW3D=no
LUCID_LIBW=
if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
if test "$with_xaw3d" != no; then
AC_MSG_CHECKING(for xaw3d)
AC_CACHE_VAL(emacs_cv_xaw3d,
[AC_LINK_IFELSE([AC_LANG_PROGRAM([[
#include <X11/Intrinsic.h>
@ -2145,6 +2143,7 @@ if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
emacs_cv_xaw3d=no
fi
if test $emacs_cv_xaw3d = yes; then
AC_MSG_CHECKING(for xaw3d)
AC_MSG_RESULT([yes; using Lucid toolkit])
USE_X_TOOLKIT=LUCID
HAVE_XAW3D=yes
@ -2152,6 +2151,7 @@ if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
AC_DEFINE(HAVE_XAW3D, 1,
[Define to 1 if you have the Xaw3d library (-lXaw3d).])
else
AC_MSG_CHECKING(for xaw3d)
AC_MSG_RESULT(no)
AC_MSG_CHECKING(for libXaw)
AC_CACHE_VAL(emacs_cv_xaw,
@ -2766,8 +2766,8 @@ if test $emacs_cv_netdb_declares_h_errno = yes; then
AC_DEFINE(HAVE_H_ERRNO, 1, [Define to 1 if netdb.h declares h_errno.])
fi
# fmod, logb, and frexp are found in -lm on most systems.
# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
# sqrt and other floating-point functions such as fmod and frexp
# are found in -lm on most systems.
AC_CHECK_LIB(m, sqrt)
# Check for mail-locking functions in a "mail" library. Probably this should
@ -2847,7 +2847,7 @@ AC_SUBST(BLESSMAIL_TARGET)
AC_CHECK_FUNCS(gethostname \
closedir getrusage get_current_dir_name \
lrand48 logb frexp fmod cbrt setsid \
lrand48 setsid \
fpathconf select euidaccess getpagesize setlocale \
utimes getrlimit setrlimit setpgid getcwd shutdown getaddrinfo \
__fpending strsignal setitimer \
@ -3227,6 +3227,14 @@ else
AC_MSG_RESULT(no)
fi
dnl Check for a Solaris 2.4 vfork bug that Autoconf misses (through 2.69).
dnl This can be removed once we assume Autoconf 2.70.
case $canonical in
*-solaris2.4 | *-solaris2.4.*)
dnl Disable the Autoconf-generated vfork test.
: ${ac_cv_func_vfork_works=no};;
esac
AC_FUNC_FORK
AC_CHECK_FUNCS(snprintf)
@ -3277,12 +3285,6 @@ AC_DEFINE(CLASH_DETECTION, 1, [Define if you want lock files to be written,
so that Emacs can tell instantly when you try to modify a file that
someone else has modified in his/her Emacs.])
AH_TEMPLATE(FLOAT_CHECK_DOMAIN, [Define if the float library doesn't
handle errors by either setting errno, or signaling SIGFPE/SIGILL.])
AH_TEMPLATE(HAVE_INVERSE_HYPERBOLIC, [Define if you have the functions
acosh, asinh, and atanh.])
dnl Everybody supports this, except MS.
dnl Seems like the kind of thing we should be testing for, though.
## Note: PTYs are broken on darwin <6. Use at your own risk.
@ -3343,10 +3345,6 @@ esac
case $opsys in
darwin | gnu | hpux* | *bsd )
AC_DEFINE(NO_TERMIO, 1, [Define if termio.h should not be included.])
;;
irix6-5 | sol2* | unixware )
dnl Some SVr4s don't define NSIG in sys/signal.h for ANSI environments;
dnl instead, there's a system variable _sys_nsig. Unfortunately, we
@ -3356,26 +3354,16 @@ case $opsys in
;;
esac
emacs_broken_SIGIO=no
case $opsys in
dnl SIGIO exists, but the feature doesn't work in the way Emacs needs.
dnl See eg <http://article.gmane.org/gmane.os.openbsd.ports/46831>.
hpux* | irix6-5 | openbsd | sol2* | unixware )
AC_DEFINE(BROKEN_SIGIO, 1, [Define if SIGIO should not be used.])
emacs_broken_SIGIO=yes
;;
aix4-2)
dnl BUILD 9008 - FIONREAD problem still exists in X-Windows.
AC_DEFINE(BROKEN_FIONREAD, 1, [Define if FIONREAD should not be used.])
dnl As we define BROKEN_FIONREAD, SIGIO will be undefined in systty.h.
dnl But, on AIX, SIGAIO, SIGPTY, and SIGPOLL are defined as SIGIO,
dnl which causes compilation error at init_signals in sysdep.c.
dnl So, we define these macros so that syssignal.h detects them
dnl and undefine SIGAIO, SIGPTY and SIGPOLL.
AC_DEFINE(BROKEN_SIGAIO, 1, [Define if SIGAIO should not be used.])
AC_DEFINE(BROKEN_SIGPOLL,1, [Define if SIGPOLL should not be used.])
AC_DEFINE(BROKEN_SIGPTY, 1, [Define if SIGPTY should not be used.])
dnl On AIX Emacs uses the gmalloc.c malloc implementation. But given
dnl the way this system works, libc functions that return malloced
dnl memory use the libc malloc implementation. Calling xfree or
@ -3417,12 +3405,6 @@ case $opsys in
AC_DEFINE(BROKEN_PTY_READ_AFTER_EAGAIN, 1, [Define on FreeBSD to
work around an issue when reading from a PTY.])
;;
dnl Define the following so emacs symbols will not conflict with those
dnl in the System framework. Otherwise -prebind will not work.
darwin)
AC_DEFINE(NO_ABORT, 1, [Do not define abort in emacs.c.])
;;
esac
case $opsys in
@ -3457,7 +3439,7 @@ dnl The choice is controlled by the variable interrupt_input.
dnl
dnl Define INTERRUPT_INPUT to make interrupt_input = 1 the default (use SIGIO)
dnl
dnl Emacs uses the presence or absence of the SIGIO and BROKEN_SIGIO macros
dnl Emacs uses the presence of the USABLE_SIGIO macro
dnl to indicate whether or not signal-driven I/O is possible. It uses
dnl INTERRUPT_INPUT to decide whether to use it by default.
dnl
@ -3517,7 +3499,7 @@ case $opsys in
cygwin )
AC_DEFINE(PTY_ITERATION, [int i; for (i = 0; i < 1; i++)])
dnl multi-line AC_DEFINEs are hard. :(
AC_DEFINE(PTY_OPEN, [ do { int dummy; SIGMASKTYPE mask; mask = sigblock (sigmask (SIGCHLD)); if (-1 == openpty (&fd, &dummy, pty_name, 0, 0)) fd = -1; sigsetmask (mask); if (fd >= 0) emacs_close (dummy); } while (0)])
AC_DEFINE(PTY_OPEN, [ do { int dummy; sigset_t blocked, procmask; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, &procmask); if (-1 == openpty (&fd, &dummy, pty_name, 0, 0)) fd = -1; pthread_sigmask (SIG_SETMASK, &procmask, 0); if (fd >= 0) emacs_close (dummy); } while (0)])
AC_DEFINE(PTY_NAME_SPRINTF, [])
AC_DEFINE(PTY_TTY_NAME_SPRINTF, [])
;;
@ -3546,7 +3528,7 @@ case $opsys in
AC_DEFINE(PTY_ITERATION, [int i; for (i = 0; i < 1; i++)])
dnl Note that grantpt and unlockpt may fork. We must block SIGCHLD
dnl to prevent sigchld_handler from intercepting the child's death.
AC_DEFINE(PTY_TTY_NAME_SPRINTF, [{ char *ptyname; sigblock (sigmask (SIGCHLD)); if (grantpt (fd) == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname(fd))) { sigunblock (sigmask (SIGCHLD)); close (fd); return -1; } snprintf (pty_name, sizeof pty_name, "%s", ptyname); sigunblock (sigmask (SIGCHLD)); }])
AC_DEFINE(PTY_TTY_NAME_SPRINTF, [{ char *ptyname = 0; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); if (grantpt (fd) != -1 && unlockpt (fd) != -1) ptyname = ptsname(fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (!ptyname) { close (fd); return -1; } snprintf (pty_name, sizeof pty_name, "%s", ptyname); }])
dnl if HAVE_POSIX_OPENPT
if test "x$ac_cv_func_posix_openpt" = xyes; then
AC_DEFINE(PTY_OPEN, [fd = posix_openpt (O_RDWR | O_NOCTTY)])
@ -3591,18 +3573,15 @@ case $opsys in
;;
sol2* )
dnl Uses sigblock/sigunblock rather than sighold/sigrelse,
dnl which appear to be BSD4.1 specific. It may also be appropriate
dnl for SVR4.x (x<2) but I'm not sure. fnf@cygnus.com
dnl On SysVr4, grantpt(3) forks a subprocess, so keep sigchld_handler()
dnl from intercepting that death. If any child but grantpt's should die
dnl within, it should be caught after sigrelse(2).
AC_DEFINE(PTY_TTY_NAME_SPRINTF, [{ char *ptsname (int), *ptyname; sigblock (sigmask (SIGCLD)); if (grantpt (fd) == -1) { emacs_close (fd); return -1; } sigunblock (sigmask (SIGCLD)); if (unlockpt (fd) == -1) { emacs_close (fd); return -1; } if (!(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, sizeof pty_name, "%s", ptyname); }])
AC_DEFINE(PTY_TTY_NAME_SPRINTF, [{ char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, sizeof pty_name, "%s", ptyname); }])
;;
unixware )
dnl Comments are as per sol2*.
AC_DEFINE(PTY_TTY_NAME_SPRINTF, [{ char *ptsname (int), *ptyname; sigblock(sigmask(SIGCLD)); if (grantpt(fd) == -1) fatal("could not grant slave pty"); sigunblock(sigmask(SIGCLD)); if (unlockpt(fd) == -1) fatal("could not unlock slave pty"); if (!(ptyname = ptsname(fd))) fatal ("could not enable slave pty"); snprintf (pty_name, sizeof pty_name, "%s", ptyname); }])
AC_DEFINE(PTY_TTY_NAME_SPRINTF, [{ char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1) fatal("could not grant slave pty"); if (unlockpt(fd) == -1) fatal("could not unlock slave pty"); if (!(ptyname = ptsname(fd))) fatal ("could not enable slave pty"); snprintf (pty_name, sizeof pty_name, "%s", ptyname); }])
;;
esac
@ -3857,13 +3836,38 @@ else
esac
fi dnl GCC?
AC_CACHE_CHECK([for _setjmp], [emacs_cv_func__setjmp],
[AC_LINK_IFELSE(
[AC_LANG_PROGRAM(
[[#include <setjmp.h>
]],
[[jmp_buf j;
if (! _setjmp (j))
_longjmp (j, 1);]])],
[emacs_cv_func__setjmp=yes],
[emacs_cv_func__setjmp=no])])
if test $emacs_cv_func__setjmp = yes; then
AC_DEFINE([HAVE__SETJMP], 1, [Define to 1 if _setjmp and _longjmp work.])
else
AC_CACHE_CHECK([for sigsetjmp], [emacs_cv_func_sigsetjmp],
[AC_LINK_IFELSE(
[AC_LANG_PROGRAM(
[[#include <setjmp.h>
]],
[[sigjmp_buf j;
if (! sigsetjmp (j, 1))
siglongjmp (j, 1);]])],
[emacs_cv_func_sigsetjmp=yes],
[emacs_cv_func_sigsetjmp=no])])
if test $emacs_cv_func_sigsetjmp = yes; then
AC_DEFINE([HAVE_SIGSETJMP], 1,
[Define to 1 if sigsetjmp and siglongjmp work.
The value of this symbol is irrelevant if HAVE__SETJMP is defined.])
fi
fi
case $opsys in
sol2* | unixware )
dnl setjmp and longjmp can safely replace _setjmp and _longjmp,
dnl but they will run more slowly.
AC_DEFINE(_setjmp, setjmp, [Some platforms redefine this.])
AC_DEFINE(_longjmp, longjmp, [Some platforms redefine this.])
dnl TIOCGPGRP is broken in SysVr4, so we can't send signals to PTY
dnl subprocesses the usual way. But TIOCSIGNAL does work for PTYs,
dnl and this is all we need.
@ -3878,13 +3882,6 @@ case $opsys in
AC_DEFINE(XOS_NEEDS_TIME_H, 1, [Compensate for a bug in Xos.h on
some systems, where it requires time.h.])
;;
netbsd | openbsd )
dnl Greg A. Woods <woods@weird.com> says we must include signal.h
dnl before syssignal.h is included, to work around interface conflicts
dnl that are handled with CPP __RENAME() macro in signal.h.
AC_DEFINE(SIGNAL_H_AHB, 1, [Define if AH_BOTTOM should include signal.h.])
;;
esac
@ -3974,6 +3971,46 @@ case $opsys in
;;
esac
AC_CACHE_CHECK([for usable FIONREAD], [emacs_cv_usable_FIONREAD],
[case $opsys in
aix4-2)
dnl BUILD 9008 - FIONREAD problem still exists in X-Windows.
emacs_cv_usable_FIONREAD=no
;;
*)
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM([[#include <sys/types.h>
#include <sys/ioctl.h>
#ifdef USG5_4
# include <sys/filio.h>
#endif
]],
[[int foo = ioctl (0, FIONREAD, &foo);]])],
[emacs_cv_usable_FIONREAD=yes],
[emacs_cv_usable_FIONREAD=no])
;;
esac])
if test $emacs_cv_usable_FIONREAD = yes; then
AC_DEFINE([USABLE_FIONREAD], [1], [Define to 1 if FIONREAD is usable.])
if test $emacs_broken_SIGIO = no; then
AC_CACHE_CHECK([for usable SIGIO], [emacs_cv_usable_SIGIO],
[AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM([[#include <fcntl.h>
#include <signal.h>
]],
[[int foo = SIGIO | F_SETFL | FASYNC;]])],
[emacs_cv_usable_SIGIO=yes],
[emacs_cv_usable_SIGIO=no])],
[emacs_cv_usable_SIGIO=yes],
[emacs_cv_usable_SIGIO=no])
if test $emacs_cv_usable_SIGIO = yes; then
AC_DEFINE([USABLE_SIGIO], [1], [Define to 1 if SIGIO is usable.])
fi
fi
fi
case $opsys in
dnl Emacs supplies its own malloc, but glib (part of Gtk+) calls
@ -3987,11 +4024,6 @@ case $opsys in
;;
hpux11)
dnl See comments in sysdep.c:sys_signal.
dnl SA_RESTART resets the timeout of `select' on hpux11.
dnl Defining BROKEN_SA_RESTART is not the same as undef'ing SA_RESTART.
AC_DEFINE(BROKEN_SA_RESTART, 1, [Define if SA_RESTART should only
be used in batch mode.])
dnl It works to open the pty's tty in the parent (Emacs), then
dnl close and reopen it in the child.
AC_DEFINE(USG_SUBTTY_WORKS, 1, [Define for USG systems where it
@ -4026,6 +4058,11 @@ fi
version=$PACKAGE_VERSION
copyright="Copyright (C) 2012 Free Software Foundation, Inc."
AC_DEFINE_UNQUOTED(COPYRIGHT, ["$copyright"],
[Short copyright string for this version of Emacs.])
AC_SUBST(copyright)
### Specify what sort of things we'll be editing into Makefile and config.h.
### Use configuration here uncanonicalized to avoid exceeding size limits.
AC_SUBST(version)
@ -4431,11 +4468,7 @@ End:
#### It makes printing result more understandable as using GTK sets
#### toolkit_scroll_bars to yes by default.
if test "${HAVE_GTK}" = "yes"; then
if test "${with_gtk3}" = "yes"; then
USE_X_TOOLKIT=GTK3
else
USE_X_TOOLKIT=GTK
fi
USE_X_TOOLKIT=GTK
fi
echo "
@ -4523,6 +4556,16 @@ fi
test "${exec_prefix}" != NONE &&
exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`]
if test "$HAVE_NS" = "yes"; then
if test "$NS_IMPL_GNUSTEP" = yes; then
AC_CONFIG_FILES([nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist:nextstep/templates/Info-gnustep.plist.in \
nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in])
else
AC_CONFIG_FILES([nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in \
nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings:nextstep/templates/InfoPlist.strings.in])
fi
fi
dnl Obviously there is duplication here wrt $SUBDIR_MAKEFILES.
dnl You _can_ use that variable in AC_CONFIG_FILES, so long as any directory
dnl using automake (ie lib/) is explicitly listed and not "hidden" in a variable
@ -4531,12 +4574,12 @@ dnl This will work, but you get a config.status that is not quite right
dnl (see http://lists.gnu.org/archive/html/bug-autoconf/2008-08/msg00028.html).
dnl That doesn't have any obvious consequences for Emacs, but on the whole
dnl it seems better to just live with the duplication.
SUBDIR_MAKEFILES="lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile"
SUBDIR_MAKEFILES="lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile nextstep/Makefile"
AC_CONFIG_FILES([Makefile lib/Makefile lib-src/Makefile oldXMenu/Makefile \
doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile \
doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile \
leim/Makefile])
leim/Makefile nextstep/Makefile])
dnl test/ is not present in release tarfiles.
opt_makefile=test/automated/Makefile

View file

@ -1,8 +1,29 @@
2012-09-17 Chong Yidong <cyd@gnu.org>
* building.texi (GDB User Interface Layout): Remove reference to
removed variable gdb-use-separate-io-buffer (Bug#12454).
2012-09-08 Jambunathan K <kjambunathan@gmail.com>
* regs.texi (Text Registers): `C-x r +' can now be used instead of
M-x append-to-register. New option `register-separator'.
(Number Registers): Mention that `C-x r +' is polymorphic.
2012-09-07 Chong Yidong <cyd@gnu.org>
* windows.texi (Window Choice): Don't mention obsolete
display-buffer-reuse-frames.
2012-09-04 Paul Eggert <eggert@cs.ucla.edu>
Give more-useful info on a fatal error (Bug#12328).
* trouble.texi (Crashing): New section, documenting this.
2012-08-24 Michael Albinus <michael.albinus@gmx.de>
* cmdargs.texi (General Variables): Setting
$DBUS_SESSION_BUS_ADDRESS to a dummy value suppresses connections
to the D-Bus session bus. (Bug#12112)
* cmdargs.texi (General Variables):
Setting $DBUS_SESSION_BUS_ADDRESS to a dummy value suppresses
connections to the D-Bus session bus. (Bug#12112)
2012-08-14 Eli Zaretskii <eliz@gnu.org>

View file

@ -888,10 +888,6 @@ displays the following frame layout:
@end group
@end smallexample
However, if @code{gdb-use-separate-io-buffer} is @code{nil}, the I/O
buffer does not appear and the primary source buffer occupies the full
width of the frame.
@findex gdb-restore-windows
@findex gdb-many-windows
If you ever change the window layout, you can restore the ``many

View file

@ -1136,6 +1136,7 @@ Dealing with Emacs Trouble
* Screen Garbled:: Garbage on the screen.
* Text Garbled:: Garbage in the text.
* Memory Full:: How to cope when you run out of memory.
* Crashing:: What Emacs does when it crashes.
* After a Crash:: Recovering editing in an Emacs session that crashed.
* Emergency Escape:: What to do if Emacs stops responding.
@ -1320,7 +1321,7 @@ when you get it, not just free for the manufacturer.
If you find GNU Emacs useful, please @strong{send a donation} to the
Free Software Foundation to support our work. Donations to the Free
Software Foundation are tax deductible in the US. If you use GNU Emacs
at your workplace, please suggest that the company make a donation.
at your workplace, please suggest that the company make a donation.
For more information on how you can help, see
@url{http://www.gnu.org/help/help.html}.

View file

@ -92,6 +92,13 @@ Copy region into register @var{r} (@code{copy-to-register}).
Insert text from register @var{r} (@code{insert-register}).
@item M-x append-to-register @key{RET} @var{r}
Append region to text in register @var{r}.
@kindex C-x r +
When register @var{r} contains text, you can use @kbd{C-x r +}
(@code{increment-register}) to append to that register. Note that
command @kbd{C-x r +} behaves differently if @var{r} contains a
number. @xref{Number Registers}.
@item M-x prepend-to-register @key{RET} @var{r}
Prepend region to text in register @var{r}.
@end table
@ -116,6 +123,19 @@ region after appending it to the register. The command
the region text to the text in the register instead of
@emph{appending} it.
@vindex register-separator
When you are collecting text using @code{append-to-register} and
@code{prepend-to-register}, you may want to separate individual
collected pieces using a separator. In that case, configure a
@code{register-separator} and store the separator text in to that
register. For example, to get double newlines as text separator
during the collection process, you can use the following setting.
@example
(setq register-separator ?+)
(set-register register-separator "\n\n")
@end example
@kindex C-x r i
@findex insert-register
@kbd{C-x r i @var{r}} inserts in the buffer the text from register
@ -191,8 +211,10 @@ Store @var{number} into register @var{r} (@code{number-to-register}).
@item C-u @var{number} C-x r + @var{r}
@kindex C-x r +
@findex increment-register
Increment the number in register @var{r} by @var{number}
(@code{increment-register}).
If @var{r} contains a number, increment the number in that register by
@var{number}. Note that command @kbd{C-x r +}
(@code{increment-register}) behaves differently if @var{r} contains
text. @xref{Text Registers}.
@item C-x r i @var{r}
Insert the number from register @var{r} into the buffer.
@end table

View file

@ -149,6 +149,7 @@ Emacs.
* Screen Garbled:: Garbage on the screen.
* Text Garbled:: Garbage in the text.
* Memory Full:: How to cope when you run out of memory.
* Crashing:: What Emacs does when it crashes.
* After a Crash:: Recovering editing in an Emacs session that crashed.
* Emergency Escape:: What to do if Emacs stops responding.
@end menu
@ -277,6 +278,44 @@ editing in the same Emacs session.
out of memory, because the buffer menu needs a fair amount of memory
itself, and the reserve supply may not be enough.
@node Crashing
@subsection When Emacs Crashes
Emacs is not supposed to crash, but if it does, before it exits it
reports some information about the crash to the standard error stream
@code{stderr}. This report may be useful to someone who later debugs
the same version of Emacs on the same platform. The format of this
report depends on the platform, and some platforms support backtraces.
Here is an example, generated on x86-64 GNU/Linux with version 2.15 of
the GNU C Library:
@example
Fatal error 11: Segmentation fault
Backtrace:
emacs[0x5094e4]
emacs[0x4ed3e6]
emacs[0x4ed504]
/lib64/libpthread.so.0[0x375220efe0]
/lib64/libpthread.so.0(read+0xe)[0x375220e08e]
emacs[0x509af6]
emacs[0x5acc26]
emacs[0x5adbfb]
emacs[0x56566b]
emacs[0x59bac3]
emacs[0x565151]
...
@end example
@noindent
The number @samp{11} is the system signal number that corresponds to
the problem, a segmentation fault here. The hexadecimal program
addresses can be useful in debugging sessions. For example, the GDB
command @samp{list *0x509af6} prints the source-code lines
corresponding to the @samp{emacs[0x509af6]} entry in the backtrace.
The three dots at the end indicate that Emacs suppressed further
backtrace entries, in the interest of brevity.
@node After a Crash
@subsection Recovery After a Crash

View file

@ -378,12 +378,10 @@ adding the desired buffer's name to the list
expression to the list @code{same-window-regexps}. By default, these
variables are @code{nil}, so this step is skipped.
@vindex display-buffer-reuse-frames
@item
Otherwise, if the buffer is already displayed in an existing window,
``reuse'' that window. Normally, only windows on the selected frame
are considered, but windows on other frames are also reusable if you
change @code{display-buffer-reuse-frames} to @code{t}, or if you
change @code{pop-up-frames} (see below) to @code{t}.
@item

View file

@ -1,3 +1,56 @@
2012-09-11 Paul Eggert <eggert@cs.ucla.edu>
Simplify, document, and port floating-point (Bug#12381).
* numbers.texi (Float Basics, Arithmetic Operations, Math Functions):
Document that / and mod (with floating point arguments), along
with asin, acos, log, log10, expt and sqrt, return special values
instead of signaling exceptions.
(Float Basics): Document that logb operates on the absolute value
of its argument.
(Math Functions): Document that (log ARG BASE) also returns NaN if
BASE is negative. Document that (expt X Y) returns NaN if X is a
finite negative number and Y a finite non-integer.
2012-09-09 Chong Yidong <cyd@gnu.org>
* lists.texi (Sets And Lists): Explain that the return value for
delete should be used, like for delq.
* minibuf.texi (Yes-or-No Queries): Document recentering and
scrolling in y-or-n-p. Remove gratuitous example.
* searching.texi (Search and Replace): Document window scrolling
entries in query-replace-map.
2012-09-08 Chong Yidong <cyd@gnu.org>
* syntax.texi (Syntax Table Internals): Define "raw syntax
descriptor" terminology (Bug#12383).
(Syntax Descriptors): Mention raw syntax descriptors.
2012-09-07 Chong Yidong <cyd@gnu.org>
* variables.texi (Creating Buffer-Local): Fix description of
local-variable-if-set-p (Bug#10713).
* eval.texi (Intro Eval): Add index entry for sexp (Bug#12233).
* windows.texi (Display Action Functions)
(Choosing Window Options): Remove obsolete variable
display-buffer-reuse-frames.
(Switching Buffers): Minor doc tweak for switch-to-buffer.
* positions.texi (Narrowing): Document buffer-narrowed-p.
* markers.texi (Moving Markers): Add xref to Point (Bug#7151).
* syntax.texi (Low-Level Parsing): Add xref to Parser State
(Bug#12269).
2012-09-04 Lars Ingebrigtsen <larsi@gnus.org>
* debugging.texi (Explicit Debug): Document `debug-on-message'.
2012-09-02 Chong Yidong <cyd@gnu.org>
* windows.texi (Window Configurations): Recommend against using

View file

@ -2738,17 +2738,6 @@ This function converts the string or vector @var{key} to a list of
individual events, which you can put in @code{unread-command-events}.
@end defun
@ignore
@defvar unread-command-char
This variable holds a character to be read as command input.
A value of -1 means ``empty''.
This variable is mostly obsolete now that you can use
@code{unread-command-events} instead; it exists only to support programs
written for Emacs versions 18 and earlier.
@end defvar
@end ignore
@defun input-pending-p
@cindex waiting for command key input
This function determines whether any command input is currently

View file

@ -298,6 +298,11 @@ of @code{(debug)} isn't ignored, it will alter the execution of the
program!) The most common suitable places are inside a @code{progn} or
an implicit @code{progn} (@pxref{Sequencing}).
If you don't know exactly where in the source code you want to put
the debug statement, but you want to display a backtrace when a
certain message is displayed, you can set @code{debug-on-message} to a
regular expression matching the desired message.
@node Using Debugger
@subsection Using the Debugger

View file

@ -40,6 +40,7 @@ interpreter.
@cindex form
@cindex expression
@cindex S-expression
@cindex sexp
A Lisp object that is intended for evaluation is called a @dfn{form}
or @dfn{expression}@footnote{It is sometimes also referred to as an
@dfn{S-expression} or @dfn{sexp}, but we generally do not use this

View file

@ -1293,14 +1293,19 @@ compare @var{object} against the elements of the list. For example:
@defun delq object list
@cindex deleting list elements
This function destructively removes all elements @code{eq} to
@var{object} from @var{list}. The letter @samp{q} in @code{delq} says
that it uses @code{eq} to compare @var{object} against the elements of
the list, like @code{memq} and @code{remq}.
@var{object} from @var{list}, and returns the resulting list. The
letter @samp{q} in @code{delq} says that it uses @code{eq} to compare
@var{object} against the elements of the list, like @code{memq} and
@code{remq}.
Typically, when you invoke @code{delq}, you should use the return
value by assigning it to the variable which held the original list.
The reason for this is explained below.
@end defun
When @code{delq} deletes elements from the front of the list, it does so
simply by advancing down the list and returning a sublist that starts
after those elements:
The @code{delq} function deletes elements from the front of the list
by simply advancing down the list, and returning a sublist that starts
after those elements. For example:
@example
@group
@ -1308,6 +1313,7 @@ after those elements:
@end group
@end example
@noindent
When an element to be deleted appears in the middle of the list,
removing it involves changing the @sc{cdr}s (@pxref{Setcdr}).
@ -1432,12 +1438,15 @@ Compare this with @code{memq}:
@end defun
@defun delete object sequence
If @code{sequence} is a list, this function destructively removes all
elements @code{equal} to @var{object} from @var{sequence}. For lists,
@code{delete} is to @code{delq} as @code{member} is to @code{memq}: it
uses @code{equal} to compare elements with @var{object}, like
@code{member}; when it finds an element that matches, it cuts the
element out just as @code{delq} would.
This function removes all elements @code{equal} to @var{object} from
@var{sequence}, and returns the resulting sequence.
If @var{sequence} is a list, @code{delete} is to @code{delq} as
@code{member} is to @code{memq}: it uses @code{equal} to compare
elements with @var{object}, like @code{member}; when it finds an
element that matches, it cuts the element out just as @code{delq}
would. As with @code{delq}, you should typically use the return value
by assigning it to the variable which held the original list.
If @code{sequence} is a vector or string, @code{delete} returns a copy
of @code{sequence} with all elements @code{equal} to @code{object}

View file

@ -355,9 +355,9 @@ the current buffer.
If @var{position} is less than 1, @code{set-marker} moves @var{marker}
to the beginning of the buffer. If @var{position} is greater than the
size of the buffer, @code{set-marker} moves marker to the end of the
buffer. If @var{position} is @code{nil} or a marker that points
nowhere, then @var{marker} is set to point nowhere.
size of the buffer (@pxref{Point}), @code{set-marker} moves marker to
the end of the buffer. If @var{position} is @code{nil} or a marker
that points nowhere, then @var{marker} is set to point nowhere.
The value returned is @var{marker}.

View file

@ -1888,47 +1888,14 @@ Echo Area}), which uses the same screen space as the minibuffer. The
cursor moves to the echo area while the question is being asked.
The answers and their meanings, even @samp{y} and @samp{n}, are not
hardwired. The keymap @code{query-replace-map} specifies them.
@xref{Search and Replace}.
In the following example, the user first types @kbd{q}, which is
invalid. At the next prompt the user types @kbd{y}.
@c Need an interactive example, because otherwise the return value
@c obscures the display of the valid answer.
@smallexample
@group
(defun ask ()
(interactive)
(y-or-n-p "Do you need a lift? "))
;; @r{After evaluation of the preceding definition, @kbd{M-x ask}}
;; @r{causes the following prompt to appear in the echo area:}
@end group
@group
---------- Echo area ----------
Do you need a lift? (y or n)
---------- Echo area ----------
@end group
;; @r{If the user then types @kbd{q}, the following appears:}
@group
---------- Echo area ----------
Please answer y or n. Do you need a lift? (y or n)
---------- Echo area ----------
@end group
;; @r{When the user types a valid answer,}
;; @r{it is displayed after the question:}
@group
---------- Echo area ----------
Do you need a lift? (y or n) y
---------- Echo area ----------
@end group
@end smallexample
hardwired, and are specified by the keymap @code{query-replace-map}
(@pxref{Search and Replace}). In particular, if the user enters the
special responses @code{recenter}, @code{scroll-up},
@code{scroll-down}, @code{scroll-other-window}, or
@code{scroll-other-window-down} (respectively bound to @kbd{C-l},
@kbd{C-v}, @kbd{M-v}, @kbd{C-M-v} and @kbd{C-M-S-v} in
@code{query-replace-map}), this function performs the specified window
recentering or scrolling operation, and poses the question again.
@noindent
We show successive lines of echo area messages, but only one actually

View file

@ -196,6 +196,14 @@ numerical functions return such values in cases where there is no
correct answer. For example, @code{(/ 0.0 0.0)} returns a NaN. (NaN
values can also carry a sign, but for practical purposes there's no
significant difference between different NaN values in Emacs Lisp.)
When a function is documented to return a NaN, it returns an
implementation-defined value when Emacs is running on one of the
now-rare platforms that do not use @acronym{IEEE} floating point. For
example, @code{(log -1.0)} typically returns a NaN, but on
non-@acronym{IEEE} platforms it returns an implementation-defined
value.
Here are the read syntaxes for these special floating point values:
@table @asis
@ -241,7 +249,7 @@ numbers.
@defun logb number
This function returns the binary exponent of @var{number}. More
precisely, the value is the logarithm of @var{number} base 2, rounded
precisely, the value is the logarithm of |@var{number}| base 2, rounded
down to an integer.
@example
@ -694,7 +702,8 @@ arguments. It also permits floating point arguments; it rounds the
quotient downward (towards minus infinity) to an integer, and uses that
quotient to compute the remainder.
An @code{arith-error} results if @var{divisor} is 0.
If @var{divisor} is zero, @code{mod} signals an @code{arith-error}
error if both arguments are integers, and returns a NaN otherwise.
@example
@group
@ -1096,8 +1105,8 @@ pi/2
@tex
@math{\pi/2}
@end tex
(inclusive) whose sine is @var{arg}; if, however, @var{arg} is out of
range (outside [@minus{}1, 1]), it signals a @code{domain-error} error.
(inclusive) whose sine is @var{arg}. If @var{arg} is out of range
(outside [@minus{}1, 1]), @code{asin} returns a NaN.
@end defun
@defun acos arg
@ -1108,8 +1117,8 @@ pi
@tex
@math{\pi}
@end tex
(inclusive) whose cosine is @var{arg}; if, however, @var{arg} is out
of range (outside [@minus{}1, 1]), it signals a @code{domain-error} error.
(inclusive) whose cosine is @var{arg}. If @var{arg} is out of range
(outside [@minus{}1, 1]), @code{acos} returns a NaN.
@end defun
@defun atan y &optional x
@ -1141,8 +1150,8 @@ This is the exponential function; it returns @math{e} to the power
@defun log arg &optional base
This function returns the logarithm of @var{arg}, with base
@var{base}. If you don't specify @var{base}, the natural base
@math{e} is used. If @var{arg} is negative, it signals a
@code{domain-error} error.
@math{e} is used. If @var{arg} or @var{base} is negative, @code{log}
returns a NaN.
@end defun
@ignore
@ -1160,21 +1169,21 @@ lose accuracy.
@end ignore
@defun log10 arg
This function returns the logarithm of @var{arg}, with base 10. If
@var{arg} is negative, it signals a @code{domain-error} error.
@code{(log10 @var{x})} @equiv{} @code{(log @var{x} 10)}, at least
approximately.
This function returns the logarithm of @var{arg}, with base 10:
@code{(log10 @var{x})} @equiv{} @code{(log @var{x} 10)}.
@end defun
@defun expt x y
This function returns @var{x} raised to power @var{y}. If both
arguments are integers and @var{y} is positive, the result is an
integer; in this case, overflow causes truncation, so watch out.
If @var{x} is a finite negative number and @var{y} is a finite
non-integer, @code{expt} returns a NaN.
@end defun
@defun sqrt arg
This returns the square root of @var{arg}. If @var{arg} is negative,
it signals a @code{domain-error} error.
@code{sqrt} returns a NaN.
@end defun
In addition, Emacs defines the following common mathematical

View file

@ -874,18 +874,18 @@ commands to a limited range of characters in a buffer. The text that
remains addressable is called the @dfn{accessible portion} of the
buffer.
Narrowing is specified with two buffer positions which become the
beginning and end of the accessible portion. For most editing commands
and most Emacs primitives, these positions replace the values of the
beginning and end of the buffer. While narrowing is in effect, no text
outside the accessible portion is displayed, and point cannot move
outside the accessible portion.
Narrowing is specified with two buffer positions, which become the
beginning and end of the accessible portion. For most editing
commands and primitives, these positions replace the values of the
beginning and end of the buffer. While narrowing is in effect, no
text outside the accessible portion is displayed, and point cannot
move outside the accessible portion. Note that narrowing does not
alter actual buffer positions (@pxref{Point}); it only determines
which positions are considered the accessible portion of the buffer.
Most functions refuse to operate on text that is outside the
accessible portion.
Values such as positions or line numbers, which usually count from the
beginning of the buffer, do so despite narrowing, but the functions
which use them refuse to operate on text that is inaccessible.
The commands for saving buffers are unaffected by narrowing; they save
Commands for saving buffers are unaffected by narrowing; they save
the entire buffer regardless of any narrowing.
If you need to display in a single buffer several very different
@ -924,6 +924,11 @@ It is equivalent to the following expression:
@end example
@end deffn
@defun buffer-narrowed-p
This function returns non-@code{nil} if the buffer is narrowed, and
@code{nil} otherwise.
@end defun
@defspec save-restriction body@dots{}
This special form saves the current bounds of the accessible portion,
evaluates the @var{body} forms, and finally restores the saved bounds,

View file

@ -1796,7 +1796,13 @@ Delete the text being considered, then enter a recursive edit to replace
it.
@item recenter
Redisplay and center the window, then ask the same question again.
@itemx scroll-up
@itemx scroll-down
@itemx scroll-other-window
@itemx scroll-other-window-down
Perform the specified window scroll operation, then ask the same
question again. Only @code{y-or-n-p} and related functions use this
answer.
@item quit
Perform a quit right away. Only @code{y-or-n-p} and related functions

View file

@ -130,6 +130,10 @@ comment-ender), and the entry for @samp{/} is @samp{@w{. 14}} (i.e.,
punctuation, matching character slot unused, first character of a
comment-starter, second character of a comment-ender).
Emacs also defines @dfn{raw syntax descriptors}, which are used to
describe syntax classes at a lower level. @xref{Syntax Table
Internals}.
@menu
* Syntax Class Table:: Table of syntax classes.
* Syntax Flags:: Additional flags each character can have.
@ -531,8 +535,9 @@ the current buffer's syntax table to determine the syntax for the
underlying text character.
@item @code{(@var{syntax-code} . @var{matching-char})}
A cons cell of this format specifies the syntax for the underlying
text character. (@pxref{Syntax Table Internals})
A cons cell of this format is a raw syntax descriptor (@pxref{Syntax
Table Internals}), which directly specifies a syntax class for the
underlying text character.
@item @code{nil}
If the property is @code{nil}, the character's syntax is determined from
@ -878,6 +883,9 @@ This function parses a sexp in the current buffer starting at
@var{start}, not scanning past @var{limit}. It stops at position
@var{limit} or when certain criteria described below are met, and sets
point to the location where parsing stops. It returns a parser state
@ifinfo
(@pxref{Parser State})
@end ifinfo
describing the status of the parse at the point where it stops.
@cindex parenthesis depth
@ -937,16 +945,20 @@ documented in this section. This internal format can also be assigned
as syntax properties (@pxref{Syntax Properties}).
@cindex syntax code
Each entry in a syntax table is a cons cell of the form
@code{(@var{syntax-code} . @var{matching-char})}. @var{syntax-code}
is an integer that encodes the syntax class and syntax flags,
according to the table below. @var{matching-char}, if non-@code{nil},
specifies a matching character (similar to the second character in a
syntax descriptor).
@cindex raw syntax descriptor
Each entry in a syntax table is a @dfn{raw syntax descriptor}: a
cons cell of the form @code{(@var{syntax-code}
. @var{matching-char})}. @var{syntax-code} is an integer which
encodes the syntax class and syntax flags, according to the table
below. @var{matching-char}, if non-@code{nil}, specifies a matching
character (similar to the second character in a syntax descriptor).
Here are the syntax codes corresponding to the various syntax
classes:
@multitable @columnfractions .2 .3 .2 .3
@item
@i{Syntax code} @tab @i{Class} @tab @i{Syntax code} @tab @i{Class}
@i{Code} @tab @i{Class} @tab @i{Code} @tab @i{Class}
@item
0 @tab whitespace @tab 8 @tab paired delimiter
@item
@ -967,7 +979,7 @@ syntax descriptor).
@noindent
For example, in the standard syntax table, the entry for @samp{(} is
@code{(4 . 41)}. (41 is the character code for @samp{)}.)
@code{(4 . 41)}. 41 is the character code for @samp{)}.
Syntax flags are encoded in higher order bits, starting 16 bits from
the least significant bit. This table gives the power of two which
@ -987,33 +999,35 @@ corresponds to each syntax flag.
@end multitable
@defun string-to-syntax @var{desc}
Given a syntax descriptor @var{desc}, this function returns the
corresponding internal form, a cons cell @code{(@var{syntax-code}
. @var{matching-char})}.
Given a syntax descriptor @var{desc} (a string), this function returns
the corresponding raw syntax descriptor.
@end defun
@defun syntax-after pos
This function returns the syntax code of the character in the buffer
after position @var{pos}, taking account of syntax properties as well
as the syntax table. If @var{pos} is outside the buffer's accessible
portion (@pxref{Narrowing, accessible portion}), this function returns
@code{nil}.
This function returns the raw syntax descriptor for the character in
the buffer after position @var{pos}, taking account of syntax
properties as well as the syntax table. If @var{pos} is outside the
buffer's accessible portion (@pxref{Narrowing, accessible portion}),
the return value is @code{nil}.
@end defun
@defun syntax-class syntax
This function returns the syntax class of the syntax code
@var{syntax}. (It masks off the high 16 bits that hold the flags
encoded in the syntax descriptor.) If @var{syntax} is @code{nil}, it
returns @code{nil}; this is so evaluating the expression
This function returns the syntax code for the raw syntax descriptor
@var{syntax}. More precisely, it takes the raw syntax descriptor's
@var{syntax-code} component, masks off the high 16 bits which record
the syntax flags, and returns the resulting integer.
If @var{syntax} is @code{nil}, the return value is returns @code{nil}.
This is so that the expression
@example
(syntax-class (syntax-after pos))
@end example
@noindent
where @code{pos} is outside the buffer's accessible portion, will
yield @code{nil} without throwing errors or producing wrong syntax
class codes.
evaluates to @code{nil} if @code{pos} is outside the buffer's
accessible portion, without throwing errors or returning an incorrect
code.
@end defun
@node Categories

View file

@ -1302,9 +1302,10 @@ This returns @code{t} if @var{variable} is buffer-local in buffer
@end defun
@defun local-variable-if-set-p variable &optional buffer
This returns @code{t} if @var{variable} will become buffer-local in
buffer @var{buffer} (which defaults to the current buffer) if it is
set there.
This returns @code{t} if @var{variable} either has a buffer-local
value in buffer @var{buffer}, or is automatically buffer-local.
Otherwise, it returns @code{nil}. If omitted or @code{nil},
@var{buffer} defaults to the current buffer.
@end defun
@defun buffer-local-value variable buffer

View file

@ -1492,12 +1492,10 @@ to make a buffer current to modify it in Lisp, use
@code{set-buffer}. @xref{Current Buffer}.
@deffn Command switch-to-buffer buffer-or-name &optional norecord force-same-window
This function displays @var{buffer-or-name} in the selected window,
and makes it the current buffer. (In contrast, @code{set-buffer}
makes the buffer current but does not display it; @pxref{Current
Buffer}). It is often used interactively (as the binding of @kbd{C-x
b}), as well as in Lisp programs. The return value is the buffer
switched to.
This command attempts to display @var{buffer-or-name} in the selected
window, and makes it the current buffer. It is often used
interactively (as the binding of @kbd{C-x b}), as well as in Lisp
programs. The return value is the buffer switched to.
If @var{buffer-or-name} is @code{nil}, it defaults to the buffer
returned by @code{other-buffer} (@pxref{The Buffer List}). If
@ -1506,17 +1504,18 @@ buffer, this function creates a new buffer with that name; the new
buffer's major mode is determined by the variable @code{major-mode}
(@pxref{Major Modes}).
Normally the specified buffer is put at the front of the buffer
Normally, the specified buffer is put at the front of the buffer
list---both the global buffer list and the selected frame's buffer
list (@pxref{The Buffer List}). However, this is not done if the
optional argument @var{norecord} is non-@code{nil}.
If this function is unable to display the buffer in the selected
window---usually because the selected window is a minibuffer window or
is strongly dedicated to its buffer (@pxref{Dedicated Windows})---then
it normally tries to display the buffer in some other window, in the
manner of @code{pop-to-buffer} (see below). However, if the optional
argument @var{force-same-window} is non-@code{nil}, it signals an error
Sometimes, @code{switch-to-buffer} may be unable to display the buffer
in the selected window. This happens if the selected window is a
minibuffer window, or if the selected window is strongly dedicated to
its buffer (@pxref{Dedicated Windows}). In that case, the command
normally tries to display the buffer in some other window, by invoking
@code{pop-to-buffer} (see below). However, if the optional argument
@var{force-same-window} is non-@code{nil}, it signals an error
instead.
@end deffn
@ -1728,8 +1727,7 @@ A frame means consider windows on that frame only.
@end itemize
If @var{alist} contains no @code{reusable-frames} entry, this function
normally searches just the selected frame; however, if either the
variable @code{display-buffer-reuse-frames} or the variable
normally searches just the selected frame; however, if the variable
@code{pop-up-frames} is non-@code{nil}, it searches all frames on the
current terminal. @xref{Choosing Window Options}.
@ -1769,14 +1767,6 @@ The behavior of the standard display actions of @code{display-buffer}
(@pxref{Choosing Window}) can be modified by a variety of user
options.
@defopt display-buffer-reuse-frames
If the value of this variable is non-@code{nil}, @code{display-buffer}
may search all frames on the current terminal when looking for a
window already displaying the specified buffer. The default is
@code{nil}. This variable is consulted by the action function
@code{display-buffer-reuse-window} (@pxref{Display Action Functions}).
@end defopt
@defopt pop-up-windows
If the value of this variable is non-@code{nil}, @code{display-buffer}
is allowed to split an existing window to make a new window for

View file

@ -1,3 +1,19 @@
2012-09-13 Paul Eggert <eggert@cs.ucla.edu>
* texinfo.tex: Merge from gnulib.
2012-09-12 Michael Albinus <michael.albinus@gmx.de>
Sync with Tramp 2.2.6.
* tramp.texi (Bug Reports): Cleanup caches before a test run.
* trampver.texi: Update release number.
2012-09-12 Paul Eggert <eggert@cs.ucla.edu>
* texinfo.tex: Merge from gnulib.
2012-08-06 Aurélien Aptel <aurelien.aptel@gmail.com>
* url.texi (Parsed URLs): Adjust to the code's use of defstruct

View file

@ -3,7 +3,7 @@
% Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
%
\def\texinfoversion{2012-07-29.17}
\def\texinfoversion{2012-09-12.16}
%
% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
@ -594,7 +594,7 @@
\def\:{\spacefactor=1000 }
% @* forces a line break.
\def\*{\hfil\break\hbox{}\ignorespaces}
\def\*{\unskip\hfil\break\hbox{}\ignorespaces}
% @/ allows a line break.
\let\/=\allowbreak
@ -2272,8 +2272,6 @@
\gdef\markupsetcodequoteleft{\let`\codequoteleft}
\gdef\markupsetcodequoteright{\let'\codequoteright}
\gdef\markupsetnoligaturesquoteleft{\let`\noligaturesquoteleft}
}
\let\markupsetuplqcode \markupsetcodequoteleft
@ -2282,6 +2280,9 @@
\let\markupsetuplqexample \markupsetcodequoteleft
\let\markupsetuprqexample \markupsetcodequoteright
%
\let\markupsetuplqkbd \markupsetcodequoteleft
\let\markupsetuprqkbd \markupsetcodequoteright
%
\let\markupsetuplqsamp \markupsetcodequoteleft
\let\markupsetuprqsamp \markupsetcodequoteright
%
@ -2291,8 +2292,6 @@
\let\markupsetuplqverbatim \markupsetcodequoteleft
\let\markupsetuprqverbatim \markupsetcodequoteright
\let\markupsetuplqkbd \markupsetnoligaturesquoteleft
% Allow an option to not use regular directed right quote/apostrophe
% (char 0x27), but instead the undirected quote from cmtt (char 0x0d).
% The undirected quote is ugly, so don't make it the default, but it
@ -2382,8 +2381,7 @@
\aftersmartic
}
% like \smartslanted except unconditionally uses \ttsl, and no ic.
% @var is set to this for defun arguments.
% Unconditional use \ttsl, and no ic. @var is set to this for defuns.
\def\ttslanted#1{{\ttsl #1}}
% @cite is like \smartslanted except unconditionally use \sl. We never want
@ -2695,10 +2693,6 @@
\let\email=\uref
\fi
% @kbd is like @code, except that if the argument is just one @key command,
% then @kbd has no effect.
\def\kbd#1{{\setupmarkupstyle{kbd}\def\look{#1}\expandafter\kbdfoo\look??\par}}
% @kbdinputstyle -- arg is `distinct' (@kbd uses slanted tty font always),
% `example' (@kbd uses ttsl only inside of @example and friends),
% or `code' (@kbd uses normal tty font always).
@ -2722,11 +2716,17 @@
% Default is `distinct'.
\kbdinputstyle distinct
% @kbd is like @code, except that if the argument is just one @key command,
% then @kbd has no effect.
\def\kbd#1{{\def\look{#1}\expandafter\kbdsub\look??\par}}
\def\xkey{\key}
\def\kbdfoo#1#2#3\par{\def\one{#1}\def\three{#3}\def\threex{??}%
\ifx\one\xkey\ifx\threex\three \key{#2}%
\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi}
\def\kbdsub#1#2#3\par{%
\def\one{#1}\def\three{#3}\def\threex{??}%
\ifx\one\xkey\ifx\threex\three \key{#2}%
\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
\else{\tclose{\kbdfont\setupmarkupstyle{kbd}\look}}\fi
}
% definition of @key that produces a lozenge. Doesn't adjust to text size.
%\setfont\keyrm\rmshape{8}{1000}{OT1}
@ -3269,6 +3269,20 @@
\finishedtitlepagetrue
}
% Settings used for typesetting titles: no hyphenation, no indentation,
% don't worry much about spacing, ragged right. This should be used
% inside a \vbox, and fonts need to be set appropriately first. Because
% it is always used for titles, nothing else, we call \rmisbold. \par
% should be specified before the end of the \vbox, since a vbox is a group.
%
\def\raggedtitlesettings{%
\rmisbold
\hyphenpenalty=10000
\parindent=0pt
\tolerance=5000
\ptexraggedright
}
% Macros to be used within @titlepage:
\let\subtitlerm=\tenrm
@ -3276,7 +3290,7 @@
\parseargdef\title{%
\checkenv\titlepage
\leftline{\titlefonts\rmisbold #1}
\vbox{\titlefonts \raggedtitlesettings #1\par}%
% print a rule at the page bottom also.
\finishedtitlepagefalse
\vskip4pt \hrule height 4pt width \hsize \vskip4pt
@ -4243,7 +4257,7 @@
}
\def\ifcmddefinedfail{\doignore{ifcommanddefined}}
% @ifcommandnotdefined CMD ... handlded similar to @ifclear above.
% @ifcommandnotdefined CMD ... handled similar to @ifclear above.
\makecond{ifcommandnotdefined}
\def\ifcommandnotdefined{%
\parsearg{\doifcmddefined{\else \let\next=\ifcmdnotdefinedfail}}}
@ -5579,14 +5593,6 @@
% Define @majorheading, @heading and @subheading
% NOTE on use of \vbox for chapter headings, section headings, and such:
% 1) We use \vbox rather than the earlier \line to permit
% overlong headings to fold.
% 2) \hyphenpenalty is set to 10000 because hyphenation in a
% heading is obnoxious; this forbids it.
% 3) Likewise, headings look best if no \parindent is used, and
% if justification is not attempted. Hence \raggedright.
\def\majorheading{%
{\advance\chapheadingskip by 10pt \chapbreak }%
\parsearg\chapheadingzzz
@ -5594,10 +5600,8 @@
\def\chapheading{\chapbreak \parsearg\chapheadingzzz}
\def\chapheadingzzz#1{%
{\chapfonts \vbox{\hyphenpenalty=10000\tolerance=5000
\parindent=0pt\ptexraggedright
\rmisbold #1\hfill}}%
\bigskip \par\penalty 200\relax
\vbox{\chapfonts \raggedtitlesettings #1\par}%
\nobreak\bigskip \nobreak
\suppressfirstparagraphindent
}
@ -5756,8 +5760,7 @@
%
% Typeset the actual heading.
\nobreak % Avoid page breaks at the interline glue.
\vbox{\hyphenpenalty=10000 \tolerance=5000 \parindent=0pt \ptexraggedright
\hangindent=\wd0 \centerparametersmaybe
\vbox{\raggedtitlesettings \hangindent=\wd0 \centerparametersmaybe
\unhbox0 #1\par}%
}%
\nobreak\bigskip % no page break after a chapter title
@ -5779,18 +5782,18 @@
\def\setchapterstyle #1 {\csname CHAPF#1\endcsname}
%
\def\unnchfopen #1{%
\chapoddpage {\chapfonts \vbox{\hyphenpenalty=10000\tolerance=5000
\parindent=0pt\ptexraggedright
\rmisbold #1\hfill}}\bigskip \par\nobreak
\chapoddpage
\vbox{\chapfonts \raggedtitlesettings #1\par}%
\nobreak\bigskip\nobreak
}
\def\chfopen #1#2{\chapoddpage {\chapfonts
\vbox to 3in{\vfil \hbox to\hsize{\hfil #2} \hbox to\hsize{\hfil #1} \vfil}}%
\par\penalty 5000 %
}
\def\centerchfopen #1{%
\chapoddpage {\chapfonts \vbox{\hyphenpenalty=10000\tolerance=5000
\parindent=0pt
\hfill {\rmisbold #1}\hfill}}\bigskip \par\nobreak
\chapoddpage
\vbox{\chapfonts \raggedtitlesettings \hfill #1\hfill}%
\nobreak\bigskip \nobreak
}
\def\CHAPFopen{%
\global\let\chapmacro=\chfopen
@ -7069,7 +7072,10 @@
\df \sl \hyphenchar\font=0
%
% On the other hand, if an argument has two dashes (for instance), we
% want a way to get ttsl. Let's try @var for that.
% want a way to get ttsl. We used to recommend @var for that, so
% leave the code in, but it's strange for @var to lead to typewriter.
% Nowadays we recommend @code, since the difference between a ttsl hyphen
% and a tt hyphen is pretty tiny. @code also disables ?` !`.
\def\var##1{{\setupmarkupstyle{var}\ttslanted{##1}}}%
#1%
\sl\hyphenchar\font=45

View file

@ -2853,6 +2853,9 @@ If you can identify a minimal test case that reproduces the problem,
include that with your bug report. This will make it much easier for
the development team to analyze and correct the problem.
Sometimes, there might be also problems due to Tramp caches. Flush
all caches before running the test, @ref{Cleanup remote connections}.
Before reporting the bug, you should set the verbosity level to 6
(@pxref{Traces and Profiles, Traces}) in the @file{~/.emacs} file and
repeat the bug. Then, include the contents of the @file{*tramp/foo*}

View file

@ -8,7 +8,7 @@
@c In the Tramp CVS, the version number is auto-frobbed from
@c configure.ac, so you should edit that file and run
@c "autoconf && ./configure" to change the version number.
@set trampver 2.2.6-pre
@set trampver 2.2.6
@c Other flags from configuration
@set instprefix /usr/local

View file

@ -1,3 +1,52 @@
2012-09-17 Glenn Morris <rgm@gnu.org>
* refcards/emacsver.tex: New file.
* refcards/calccard.tex, refcards/cs-dired-ref.tex:
* refcards/cs-refcard.tex, refcards/cs-survival.tex:
* refcards/de-refcard.tex, refcards/dired-ref.tex:
* refcards/emacsver.tex, refcards/fr-dired-ref.tex:
* refcards/fr-refcard.tex, refcards/fr-survival.tex:
* refcards/orgcard.tex, refcards/pl-refcard.tex:
* refcards/pt-br-refcard.tex, refcards/refcard.tex:
* refcards/sk-dired-ref.tex, refcards/sk-refcard.tex:
* refcards/sk-survival.tex, refcards/survival.tex:
* refcards/vipcard.tex, refcards/viperCard.tex: Include emacsver.tex.
* refcards/calccard.tex (\emacsversionnumber):
Rename to \versionemacs, same as all the other refcards.
* refcards/Makefile (ENVADD): New variable.
(sk-dired-ref.pdf, sk-survival.pdf, pl-refcard.pdf)
(%.pdf, %,dvi, sk-dired-ref.dvi, sk-survival.dvi, pl-refcard.dvi):
Depend on emacsver.tex. Add "." to TEXINPUTS for TeX commands.
2012-09-16 Paul Eggert <eggert@cs.ucla.edu>
Remove configure's --without-sync-input option (Bug#12450).
* TODO (Make SYNC_INPUT the default): Remove, as the code now
behaves as if SYNC_INPUT is always true.
2012-09-13 Paul Eggert <eggert@cs.ucla.edu>
Use a more backwards-compatible timer format (Bug#12430).
* NEWS: Document it, plus fix a typo.
2012-09-13 Jan Djärv <jan.h.d@swipnet.se>
* NEWS (--with-x-toolkit): Mention that Gtk+ 3 is now default.
2012-09-13 Paul Eggert <eggert@cs.ucla.edu>
* NEWS: Document timer format change (Bug#12430).
2012-09-11 Paul Eggert <eggert@cs.ucla.edu>
Simplify, document, and port floating-point (Bug#12381).
* NEWS: Document NaNs versus signaling-error change.
2012-09-04 Paul Eggert <eggert@cs.ucla.edu>
Give more-useful info on a fatal error (Bug#12328).
* NEWS: Document the change.
2012-09-01 Paul Eggert <eggert@cs.ucla.edu>
Better seeds for (random).

115
etc/NEWS
View file

@ -65,6 +65,14 @@ renamed to '--enable-check-lisp-object-type', as the resulting
Lisp_Object type no longer uses a union to implement the compile time
check that this option enables.
---
** The default toolkit has been changed to Gtk+ version 3.
If you don't pass --with-x-toolkit to configure or if you pass
--with-x-toolkit=gtk or --with-x-toolkit=yes, configure will try to build
with Gtk+ version 3, and if that fails, try Gtk+ version 2.
You can explicitly require a specific version by passing
--with-x-toolkit=gtk2 or --with-x-toolkit=gtk3 to configure.
* Startup Changes in Emacs 24.3
@ -78,6 +86,10 @@ been adding them there, put them somewhere else, eg site-lisp.
* Changes in Emacs 24.3
** You can now scroll the selected window in most y-or-n prompts.
Typing C-v or M-v at a prompt scrolls forward or backward
respectively, without leaving the y-or-n prompt.
** Help changes
*** `C-h f' (describe-function) can now perform autoloading.
@ -97,6 +109,16 @@ machines. Other functions that use this format, such as
file-attributes and format-time-string, have been changed accordingly.
Old-format time stamps are still accepted.
** The format of timers in timer-list and timer-idle-list is now
[TRIGGERED-P HI-SECS LO-SECS USECS REPEAT-DELAY FUNCTION ARGS IDLE-DELAY PSECS].
The PSECS slot is new, and uses picosecond resolution. It can be
accessed via the new timer--psecs accessor.
** Emacs now generates backtraces on fatal errors.
On encountering a fatal error, Emacs now outputs a textual description
of the fatal signal, and a short backtrace on platforms like glibc
that support backtraces.
** New functions `system-users', `system-groups' return lists of the user
name, group names known to the system (where possible).
@ -177,6 +199,14 @@ just removing them, as done by `yank-excluded-properties'.
delete-trailing-whitespace command should delete trailing lines at the
end of the buffer. It defaults to t.
+++
** `C-x r +' is now overloaded to invoke `append-to-register.
+++
** New option `register-separator' specifies the register containing
the text to put between collected texts for use with M-x
append-to-register and M-x prepend-to-register.
** Search changes
*** Global `M-s _' starts a symbol (identifier) incremental search,
@ -192,6 +222,13 @@ of one or more whitespace characters defined by the variable
`isearch-lax-whitespace'. In regexp incremental search, it toggles
the value of the variable `isearch-regexp-lax-whitespace'.
** query-replace changes
*** When new option `replace-lax-whitespace' is non-nil,
and you enter a space or spaces in the strings or regexps
to be replaced, `query-replace' will match any sequence matched
by the regexp `search-whitespace-regexp'.
** M-x move-to-column, if called interactively with no prefix arg, now
prompts for a column number.
@ -320,6 +357,14 @@ python-describe-symbol | python-eldoc-at-point
*** Accepts \r and \f as whitespace.
** SQL Mode
*** DB2 added `sql-db2-escape-newlines'
If non-nil, newlines sent to the command interpreter will be escaped
by a backslash. The default does not escape the newlines and assumes
that the sql statement will be terminated by a semicolon.
** Diff mode
Faces for changes now use the same diff color scheme as in modern VCSes
@ -331,6 +376,9 @@ The variable `diff-use-changed-face' defines whether to use
the face `diff-changed', or `diff-removed' and `diff-added'
to highlight changes in context diffs.
*** The new command `diff-remove-trailing-whitespace' fixes trailing
whitespace problems introduced by the diff.
** Ediff now uses the same color scheme as Diff mode
on high color displays.
@ -411,6 +459,13 @@ channel keys found, if any.
if the command ends in `;' (when operating on multiple files).
Otherwise, it executes the command on each file in parallel.
*** The minibuffer default for `=' (`dired-diff) has changed.
It is now the backup file for the file at point, if one exists, rather
than the file at the mark.
*** `M-=' is no longer bound to `dired-backup-diff' in Dired buffers.
The global binding for `M-=', `count-words-region' is in effect.
** Shell
*** New option `async-shell-command-buffer' specifies what buffer to use
@ -596,11 +651,18 @@ are deprecated and will be removed eventually.
*** `facemenu-unlisted-faces'
*** `rmail-decode-mime-charset'
*** `last-input-char' and `last-command-char'
*** `last-input-char', `last-command-char', `unread-command-char'.
* Lisp changes in Emacs 24.3
** Interpreted files get eagerly macro-expanded during load.
This can significantly speed up execution of non-byte-compiled code, but can
also bump into harmless and previously unnoticed cyclic dependencies.
These should not be fatal: they will simply cause the macro-calls to be left
for later expansion (as before), but will also result in a warning describing
the cycle.
** New minor mode `read-only-mode' to replace toggle-read-only (now obsolete).
** New functions `autoloadp' and `autoload-do-load'.
@ -626,26 +688,54 @@ The interpretation of the DECLS is determined by `defun-declarations-alist'.
** New error type and new function `user-error'. Doesn't trigger the debugger.
** Debugger
*** New option `debugger-bury-or-kill'.
*** Set `debug-on-message' to enter the debugger when a certain
message is displayed in the echo area. This can be useful when trying
to work out which code is doing something.
*** New var `inhibit-debugger', automatically set to prevent accidental
recursive invocations.
+++
** New utility function `buffer-narrowed-p'.
** Window changes
*** The functions get-lru-window, get-mru-window and get-largest-window
now accept a third argument to avoid choosing the selected window.
*** New display action alist `inhibit-switch-frame', if non-nil, tells
display action functions to avoid changing which frame is selected.
*** New macro `with-temp-buffer-window'.
*** New display action alist `pop-up-frame-parameters', if non-nil,
specifies frame parameters to give any newly-created frame.
*** New option `temp-buffer-resize-frames'.
*** New function `fit-frame-to-buffer' and new option
`fit-frame-to-buffer-bottom-margin'.
*** New display action functions `display-buffer-below-selected' and
`display-buffer-in-previous-window'.
*** New display action alist entry `inhibit-switch-frame', if non-nil,
tells display action functions to avoid changing which frame is
selected.
*** New display action alist entry `pop-up-frame-parameters', if
non-nil, specifies frame parameters to give any newly-created frame.
*** New display action alist entry `previous-window', if non-nil,
specifies window to reuse in `display-buffer-in-previous-window'.
*** The following variables are obsolete, as they can be replaced by
appropriate entries in the `display-buffer-alist' function introduced
in Emacs 24.1:
+++
**** `display-buffer-reuse-frames'
**** `special-display-regexps'
**** `special-display-frame-alist'
**** `special-display-buffer-names'
**** `special-display-function'
**** `display-buffer-function'
** Completion
@ -661,12 +751,21 @@ table, but with a different prefix.
must be in the range 1000..9999. It now works with any year supported
by the underlying C implementation.
** Floating point
*** When floating point functions such as `log' are given invalid
arguments, e.g., (log -1.0), they now uniformly return special values
such as NaNs instead of signaling errors. Previously, these functions
returned NaNs on some platforms but signaled errors on others. The affected
functions are acos, asin, tan, exp, expt, log, log10, sqrt, and mod.
** New function file-name-base.
** New function `tty-top-frame' returns the topmost frame of a text terminal.
** `automount-dir-prefix' is obsolete.
** `buffer-has-markers-at' is obsolete.
** `window-system-version' is obsolete.
* Changes in Emacs 24.3 on non-free operating systems
@ -1399,6 +1498,10 @@ If you had that set, you need to put
in your ~/.authinfo file instead.
*** SMTPmail defaults to using the address in the From: header as the
SMTP MAIL FROM envelope. To override this, set `mail-envelope-from'
to the address you wish to use instead.
** SQL mode
*** New options `sql-port', `sql-connection-alist', `sql-send-terminator',

View file

@ -1229,13 +1229,6 @@ systems for HTML/XML files automatically."
For use by sml-mode, python-mode, tex-mode, scheme-mode, lisp-mode,
haskell-mode, tuareg-mode, ...
** Make SYNC_INPUT the default. [true since 2008-03-11]
All loops using immediate_quit need to be checked to ensure that
C-g can interrupt them, in case of an infinite loop. Once we
switch to using SYNC_INPUT, we can remove the BLOCK_INPUTs in the
allocation functions (allocate_string etc.) without worrying about
data munging.
** Add "link" button class
Add a standard button-class named "link", and make all other link-like
button classes inherit from it. Set the default face of the "link" button

View file

@ -47,26 +47,27 @@ VIPER_CARDS_PDF = vipcard.pdf viperCard.pdf
viper-cards_pdf: ${VIPER_CARDS_PDF}
viper-cards_ps: ${VIPER_CARDS_PDF:.pdf=.ps}
ENVADD = TEXINPUTS=".:"
## PDF files.
## The page layouts (a4/letter) are written directly in the .tex files.
cs-refcard.pdf cs-dired-ref.pdf cs-survival.pdf sk-refcard.pdf \
sk-dired-ref.pdf sk-survival.pdf: %.pdf: %.tex
sk-dired-ref.pdf sk-survival.pdf: %.pdf: %.tex emacsver.tex
if pdfcsplain --version > /dev/null 2> /dev/null; then \
pdfcsplain $<; \
${ENVADD} pdfcsplain $<; \
else \
csplain "\pdfoutput=1\input $<"; \
${ENVADD} csplain "\pdfoutput=1\input $<"; \
fi
## Some versions of pdfmex seem to create dvi by default, hence output-format.
pl-refcard.pdf: %.pdf: %.tex
pl-refcard.pdf: %.pdf: %.tex emacsver.tex
if ! kpsewhich -format=fmt mex > /dev/null && \
! pdfmex --version > /dev/null 2> /dev/null; then \
echo "No mex format found."; false; \
fi
pdftex -output-format=pdf $<
${ENVADD} pdftex -output-format=pdf $<
ru-refcard.pdf: %.pdf: %.tex
pdflatex $<
@ -81,21 +82,21 @@ gnus-booklet.pdf: gnus-refcard.tex gnus-logo.pdf
pdflatex -jobname=gnus-booklet '\def\booklettrue{}\def\letterpapertrue{}\input{gnus-refcard}'
## Everything not explicitly listed above.
%.pdf: %.tex
pdftex $<
%.pdf: %.tex emacsver.tex
${ENVADD} pdftex $<
## dvi files.
cs-refcard.dvi cs-dired-ref.dvi cs-survival.dvi sk-refcard.dvi \
sk-dired-ref.dvi sk-survival.dvi: %.dvi: %.tex
csplain $<
sk-dired-ref.dvi sk-survival.dvi: %.dvi: %.tex emacsver.tex
${ENVADD} csplain $<
pl-refcard.dvi: %.dvi: %.tex
pl-refcard.dvi: %.dvi: %.tex emacsver.tex
if ! kpsewhich -format=fmt mex > /dev/null; then \
echo "No mex format found."; false; \
fi
tex $<
${ENVADD} tex $<
ru-refcard.dvi gnus-refcard.dvi: %.dvi: %.tex
latex $<
@ -105,8 +106,8 @@ gnus-booklet.dvi: gnus-refcard.tex
mv gnus-refcard.dvi $@
## Everything not explicitly listed above.
%.dvi: %.tex
tex $<
%.dvi: %.tex emacsver.tex
${ENVADD} tex $<
## PostScript files.

View file

@ -63,8 +63,7 @@
% UUCP: mit-erl!gildea
% Internet: gildea@stop.mail-abuse.org
\def\emacsversionnumber{24}
\def\year{2012} % latest copyright year
\input emacsver.tex
\def\shortcopyrightnotice{\vskip 1ex plus 2 fill
\centerline{\small \copyright\ \year\ Free Software Foundation, Inc.
@ -276,7 +275,7 @@
\title{GNU Calc Reference Card}
\centerline{(for GNU Emacs version \emacsversionnumber)}
\centerline{(for GNU Emacs version \versionemacs)}
\section{Starting and Stopping}

View file

@ -41,8 +41,7 @@
\input pdflayout.sty
\pdflayout=(0)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed.

View file

@ -59,8 +59,7 @@
\input pdflayout.sty
\pdflayout=(0)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed.

View file

@ -54,8 +54,7 @@
% Czech hyphenation rules applied
\chyph
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
\def\copyrightnotice{\penalty-1\vfill
\vbox{\smallfont\baselineskip=0.8\baselineskip\raggedcenter

View file

@ -60,8 +60,7 @@
\input german.sty
\mdqoff % deactivates the "-char
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed below this line.

View file

@ -43,8 +43,7 @@
\input pdflayout.sty
\pdflayout=(1)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed.

View file

@ -0,0 +1,4 @@
%% This file is not generated by configure, because then the provided
%% pdf files would always appear out-of-date.
\def\versionemacs{24} % major version of emacs
\def\year{2012} % latest copyright year

View file

@ -35,8 +35,7 @@
\input pdflayout.sty
\pdflayout=(0)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed.

View file

@ -56,8 +56,7 @@
\input pdflayout.sty
\pdflayout=(0l)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed below this line.

View file

@ -49,8 +49,7 @@
\input pdflayout.sty
\pdflayout=(0)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
\def\copyrightnotice{\penalty-1\vfill
\vbox{\smallfont\baselineskip=0.8\baselineskip\raggedcenter

View file

@ -1,7 +1,7 @@
% Reference Card for Org Mode
\def\orgversionnumber{7.8.11}
\def\versionyear{2012} % latest update
\def\year{2012} % latest copyright year
\input emacsver.tex
%**start of header
\newcount\columnsperpage

View file

@ -69,8 +69,7 @@
\input pdflayout.sty
\pdflayout=(0)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed.

View file

@ -62,8 +62,7 @@
\input pdflayout.sty
\pdflayout=(0l)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed below this line.

View file

@ -63,8 +63,7 @@
% Nothing else needs to be changed below this line.
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % copyright year
\input emacsver.tex
\def\shortcopyrightnotice{\vskip 1ex plus 2 fill
\centerline{\small \copyright\ \year\ Free Software Foundation, Inc.

View file

@ -42,8 +42,7 @@
\input pdflayout.sty
\pdflayout=(0)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed.

View file

@ -60,8 +60,7 @@
\input pdflayout.sty
\pdflayout=(0)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
% Nothing else needs to be changed.

View file

@ -55,8 +55,7 @@
% Slovak hyphenation rules applied
\shyph
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
\def\copyrightnotice{\penalty-1\vfill
\vbox{\smallfont\baselineskip=0.8\baselineskip\raggedcenter

View file

@ -44,8 +44,7 @@
\input pdflayout.sty
\pdflayout=(1)
\def\versionemacs{24} % version of Emacs this is for
\def\year{2012} % latest copyright year
\input emacsver.tex
\def\copyrightnotice{\penalty-1\vfill
\vbox{\smallfont\baselineskip=0.8\baselineskip\raggedcenter

View file

@ -49,8 +49,8 @@
\input pdflayout.sty
\pdflayout=(1)
\input emacsver.tex
\def\versionemacs{18} % version of Emacs this is for
\def\year{2012} % latest copyright year
\def\versionvip{3.5}
% Nothing else needs to be changed.

View file

@ -52,8 +52,8 @@
\input pdflayout.sty
\pdflayout=(1)
\input emacsver.tex
\def\versionemacs{21} % version of Emacs this is for
\def\year{2012} % latest copyright year
\def\versionxemacs{20} % version of XEmacs this is for
\def\versionviper{3.0} % version of Viper this is for

View file

@ -1,3 +1,7 @@
2012-09-05 Eli Zaretskii <eliz@gnu.org>
* quail/hebrew.el ("yiddish-royal"): Fix several bogus entries.
2012-08-17 Daniel Bergey <bergey@alum.mit.edu> (tiny change)
* quail/indian.el (quail-define-inscript-package):

View file

@ -773,9 +773,9 @@ Better for yiddish than Hebrew methods.
("@" ?,Y%(B) ; Double Low-9 Quotation Mark
("(" ?\)) ; mirroring
(")" ?\() ; mirroring
("Q" ?,A=(B) ; Right Double Quotation Mark
("W" ?,A<(B)
("E" ?,A>(B) ; Yiddish Double Yod (x2)
("Q" ?,Y4(B) ; Left Double Quotation Mark
("W" ?,Y!(B) ; Right Double Quotation Mark
("E" ?$,1-2(B) ; Yiddish Double Yod (x2)
("R" [ ",H`$,1,W(B" ]) ; Patah Alef (Pasekh Alef)
; ("T" "")
("Y" ?$,1-1(B) ; Ligature Yiddish Vav Yod (vov yud)

View file

@ -1,3 +1,13 @@
2012-09-17 Glenn Morris <rgm@gnu.org>
* ebrowse.c (version):
* etags.c (print_version): Use COPYRIGHT.
2012-09-11 Paul Eggert <eggert@cs.ucla.edu>
* pop.c (socket_connection) [HAVE_GETADDRINFO]:
Prefer assignment to memcpy when either will do.
2012-08-31 Andreas Schwab <schwab@linux-m68k.org>
* etags.c (consider_token): Always zero-terminate token buffer.

View file

@ -3516,8 +3516,7 @@ usage (int error)
static _Noreturn void
version (void)
{
/* Makes it easier to update automatically. */
char emacs_copyright[] = "Copyright (C) 2012 Free Software Foundation, Inc.";
char emacs_copyright[] = COPYRIGHT;
printf ("ebrowse %s\n", VERSION);
puts (emacs_copyright);

View file

@ -836,8 +836,7 @@ etags --help --lang=ada.");
static void
print_version (void)
{
/* Makes it easier to update automatically. */
char emacs_copyright[] = "Copyright (C) 2012 Free Software Foundation, Inc.";
char emacs_copyright[] = COPYRIGHT;
printf ("%s (%s %s)\n", (CTAGS) ? "ctags" : "etags", EMACS_NAME, VERSION);
puts (emacs_copyright);

View file

@ -1083,7 +1083,7 @@ socket_connection (char *host, int flags)
if (it->ai_addrlen == sizeof (addr))
{
struct sockaddr_in *in_a = (struct sockaddr_in *) it->ai_addr;
memcpy (&addr.sin_addr, &in_a->sin_addr, sizeof (addr.sin_addr));
addr.sin_addr = in_a->sin_addr;
if (! connect (sock, (struct sockaddr *) &addr, sizeof (addr)))
break;
}

View file

@ -66,24 +66,19 @@
# undef true
#endif
/* For the sake of symbolic names in gdb, we define true and false as
enum constants, not only as macros.
It is tempting to write
typedef enum { false = 0, true = 1 } _Bool;
so that gdb prints values of type 'bool' symbolically. But if we do
this, values of type '_Bool' may promote to 'int' or 'unsigned int'
(see ISO C 99 6.7.2.2.(4)); however, '_Bool' must promote to 'int'
(see ISO C 99 6.3.1.1.(2)). So we add a negative value to the
enum; this ensures that '_Bool' promotes to 'int'. */
#if defined __cplusplus || (defined __BEOS__ && !defined __HAIKU__)
#ifdef __cplusplus
# define _Bool bool
# define bool bool
#else
# if defined __BEOS__ && !defined __HAIKU__
/* A compiler known to have 'bool'. */
/* If the compiler already has both 'bool' and '_Bool', we can assume they
are the same types. */
# if !@HAVE__BOOL@
# if !@HAVE__BOOL@
typedef bool _Bool;
# endif
#else
# if !defined __GNUC__
# endif
# else
# if !defined __GNUC__
/* If @HAVE__BOOL@:
Some HP-UX cc and AIX IBM C compiler versions have compiler bugs when
the built-in _Bool type is used. See
@ -103,19 +98,35 @@ typedef bool _Bool;
"Invalid enumerator. (badenum)" with HP-UX cc on Tru64.
The only benefit of the enum, debuggability, is not important
with these compilers. So use 'signed char' and no enum. */
# define _Bool signed char
# else
# define _Bool signed char
# else
/* With this compiler, trust the _Bool type if the compiler has it. */
# if !@HAVE__BOOL@
# if !@HAVE__BOOL@
/* For the sake of symbolic names in gdb, define true and false as
enum constants, not only as macros.
It is tempting to write
typedef enum { false = 0, true = 1 } _Bool;
so that gdb prints values of type 'bool' symbolically. But then
values of type '_Bool' might promote to 'int' or 'unsigned int'
(see ISO C 99 6.7.2.2.(4)); however, '_Bool' must promote to 'int'
(see ISO C 99 6.3.1.1.(2)). So add a negative value to the
enum; this ensures that '_Bool' promotes to 'int'. */
typedef enum { _Bool_must_promote_to_int = -1, false = 0, true = 1 } _Bool;
# endif
# endif
# endif
# define bool _Bool
#endif
#define bool _Bool
/* The other macros must be usable in preprocessor directives. */
#define false 0
#define true 1
#ifdef __cplusplus
# define false false
# define true true
#else
# define false 0
# define true 1
#endif
#define __bool_true_false_are_defined 1
#endif /* _GL_STDBOOL_H */

View file

@ -1,3 +1,599 @@
2012-09-17 Richard Stallman <rms@gnu.org>
* epa-mail.el (epa-mail-encrypt): Fix bug when a name has no key.
2012-09-17 Chong Yidong <cyd@gnu.org>
* shell.el (shell-file-name-chars, shell-file-name-quote-list)
(shell-dynamic-complete-functions): Convert to defcustom.
(shell-prompt-pattern, shell-completion-fignore): Doc fix.
* bookmark.el (bookmark-bmenu-toggle-filenames): Doc fixes.
* comint.el (comint-prompt-read-only):
* custom.el (defcustom):
* hi-lock.el (hi-lock-mode):
* ibuffer.el (ibuffer-formats):
* ielm.el (ielm-prompt-read-only):
* novice.el (disable-command):
* saveplace.el (toggle-save-place):
* speedbar.el (speedbar-supported-extension-expressions):
* startup.el (auto-save-list-file-prefix, init-file-user)
(after-init-hook, inhibit-startup-echo-area-message):
* strokes.el (strokes-help):
* time-stamp.el (time-stamp):
* calendar/calendar.el (calendar, diary-file):
* calendar/diary-lib.el (diary-mail-entries, diary)
(diary-list-entries-hook):
* calendar/holidays.el (holidays, calendar-holidays):
* calendar/lunar.el (lunar-phases):
* calendar/solar.el (sunrise-sunset):
* emulation/edt.el (edt-load-keys):
* emulation/viper.el (viper-mode):
* eshell/em-alias.el (eshell-command-aliases-list):
* eshell/esh-util.el (eshell-convert-numeric-arguments):
* international/ogonek.el (ogonek-information):
* net/tramp-cmds.el (tramp-bug):
* net/quickurl.el (quickurl-reread-hook-postfix):
* play/decipher.el (decipher-font-lock-keywords):
* progmodes/cc-styles.el (c-set-style):
* progmodes/idlw-shell.el (idlwave-shell-prompt-pattern):
* progmodes/inf-lisp.el (inferior-lisp-prompt):
* progmodes/octave-mod.el (octave-mode):
* progmodes/sql.el (sql-mode, sql-interactive-mode, sql-password):
* progmodes/verilog-mode.el (verilog-read-defines):
* textmodes/two-column.el (2C-mode): Likewise.
2012-09-16 Katsumi Yamaoka <yamaoka@jpl.org>
* mail/mailabbrev.el (mail-abbrev-expand-hook): Work for a mail aliasee
that holds many addresses.
2012-09-16 Chong Yidong <cyd@gnu.org>
* align.el (align-areas): Call the indication function with
positions instead of markers for arguments (Bug#12343).
* files.el (parse-colon-path): Use split-string (Bug#12351).
* window.el (special-display-popup-frame): Doc fix (Bug#8853).
(display-buffer-function): Mark as obsolete.
* progmodes/compile.el (compilation-parse-errors): Accept list
values similar to font-lock-keywords (Bug#12136). Suggested by
Oleksandr Manzyuk.
(compilation-error-regexp-alist): Doc fix.
2012-09-15 Glenn Morris <rgm@gnu.org>
* version.el (emacs-bzr-version-bzr): New function.
(emacs-bzr-get-version): Add optional EXTERNAL argument.
* vc/vc-bzr.el (vc-bzr-working-revision): For lightweight local
checkouts, check the parent dirstate matches the branch.
Add "--tree" to "bzr revno" arguments. Don't try to shorten the
empty string.
* version.el (emacs-bzr-version): Doc fix.
(emacs-bzr-version-dirstate): New function.
(emacs-bzr-get-version): For lightweight checkouts, if the parent
is local try and check that it matches the branch. If not, just
use dirstate information. (Bug#12441)
2012-09-14 Juri Linkov <juri@jurta.org>
* dired-aux.el (dired-do-chmod): Use `eq' to detect empty input.
(Bug#12399)
2012-09-14 Stefan Monnier <monnier@iro.umontreal.ca>
* emacs-lisp/advice.el (ad-prognify): Remove, use macroexp-progn.
* emacs-lisp/edebug.el: Miscellaneous cleanup.
Remove obsolete byte-compiler hack that tried to silence some warnings.
(edebug-submit-bug-report): Remove.
(edebug-get-buffer-window, edebug-sit-for, edebug-input-pending-p):
Remove aliases, use the un-prefixed name instead.
(edebug-pop-to-buffer): Consider other frames.
(edebug-original-read):: Make it more obvious that it's always defined.
(edebug--make-form-data-entry, edebug--form-data-name)
(edebug--form-data-begin, edebug--form-data-end): Rename from the
single-dashed name, and implement with cl-defstruct.
(edebug-set-form-data-entry): Use the standard accessors.
(edebug-make-top-form-data-entry): Use push.
(edebug-no-match): Drop useless `funcall'.
(mapcar, mapconcat, mapatoms, apply, funcall): Don't add debug specs
to functions.
(defsubst, dont-compile, eval-when-compile, eval-and-compile)
(delay-mode-hooks, with-temp-file, with-temp-message, ad-dolist)
(with-syntax-table, push, pop, 1value, noreturn, defadvice)
(easy-menu-define, with-custom-print): Remove redundant specs.
(edebug-outside-overriding-local-map)
(edebug-outside-overriding-terminal-local-map): Remove, unused.
(edebug--display): Bind unread-command-events directly to nil rather
than binding it to unread-command-events and later setting it to nil.
(edebug--display): Kill edebug-eval-buffer here...
(edebug--recursive-edit): ...rather than here.
Bind standard-output and standard-input.
(edebug-eval): Check cl-macroexpand-all is fboundp.
(edebug-temp-display-freq-count): Fix last change.
* emacs-lisp/easymenu.el (easy-menu-define): Add `debug' spec.
* subr.el (noreturn, 1value): Add `debug' spec.
* emacs-lisp/advice.el: Require cl-lib.
(ad-copy-tree): Remove, use copy-tree instead.
(ad-dolist): Remove use dolist or cl-dolist instead.
(ad-do-return): Remove, use cl-return instead.
(defadvice): Add `debug' spec.
2012-09-13 Juri Linkov <juri@jurta.org>
* dired-aux.el (dired-do-chxxx): Use `eq' to detect empty input.
(Bug#12399)
2012-09-13 Glenn Morris <rgm@gnu.org>
* calc/calc.el (math-compose-expr):
* calc/calc-ext.el (math-compose-expr):
* progmodes/cc-defs.el (cl-macroexpand-all):
* progmodes/cc-langs.el (delete-duplicates, mapcan)
(cl-macroexpand-all): Update declarations.
* vc/vc.el: No need to require ediff.
(ediff-load-version-control): Declare.
(ediff-vc-internal): Fix declaration.
(vc-version-ediff): Require ediff.
2012-09-13 Paul Eggert <eggert@cs.ucla.edu>
Use a more backwards-compatible timer format (Bug#12430).
* emacs-lisp/timer.el (timer): PSECS is now at the end, rather than
being right after USECS, as that better supports old code that
inadvisedly looked directly at the timer vector.
2012-09-13 Kenichi Handa <handa@gnu.org>
* language/chinese.el ("Chinese-GB", "Chinese-BIG5")
("Chinese-CNS", "Chinese-EUC-TW"): Add chinese-gbk to
`coding-priority' property of these language environment.
2012-09-13 Paul Eggert <eggert@cs.ucla.edu>
Fix glitches caused by addition of psec to timers (Bug#12430).
* image.el (image-animate-timer):
* time.el (display-time-world-timer):
Use timer--function and timer--args rather than raw access to
timer vector.
2012-09-13 Glenn Morris <rgm@gnu.org>
* emacs-lisp/bytecomp.el (byte-compile-warning-prefix):
If not compiling a file, try using load-file-name.
2012-09-13 Stefan Monnier <monnier@iro.umontreal.ca>
* emacs-lisp/edebug.el (edebug-outside-unread-command-events):
Fix last change.
(edebug-update-eval-list): Use `push'.
* emacs-lisp/edebug.el: Use lexical-binding.
Remove the "edebug-" prefix from non-dynamically-scoped variables.
Mark unused args with underscore.
(edebug-save-restriction, edebug-outside-excursion): Use `declare'.
(edebug-form-data): Use defvar-local.
(edebug-make-before-and-after-form, edebug-make-after-form):
Use backquote.
(edebug-args, edebug-value, edebug-after-index, edebug-arg-mode):
Not dynamically scoped any more.
(edebug--enter-trace): Add arguments `function' and `args'.
Rename from edebug-enter-trace.
(edebug-enter): Call it accordingly. Bind edebug-function explicitly.
(edebug--update-coverage): Add `after-index' and `value' args.
Rename from edebug-update-coverage.
(edebug-slow-after): Call it accordingly.
(edebug--recursive-edit): Add arg `arg-mode'. Rename from
edebug-recursive-edit.
(edebug--display): Call it accordingly. Add args `value',
`offset-index', and `arg-mode'. Rename from edebug-display.
(edebug-debugger, edebug): Call it accordingly.
(edebug-eval-display-list): Use dolist.
2012-09-12 Juri Linkov <juri@jurta.org>
* info.el (Info-search): Don't check for isearch-mode and
isearch-regexp before let-binding search-spaces-regexp to
Info-search-whitespace-regexp.
(Info-isearch-search): Let-bind Info-search-whitespace-regexp to
search-whitespace-regexp if isearch-lax-whitespace or
isearch-regexp-lax-whitespace is non-nil.
(Info-mode): Don't set local variable search-whitespace-regexp.
http://lists.gnu.org/archive/html/emacs-devel/2012-08/msg00811.html
2012-09-12 Stefan Monnier <monnier@iro.umontreal.ca>
* emacs-lisp/debug.el (debugger-outer-unread-command-char, debug)
(debugger-env-macro): Remove support for unread-command-char.
* subr.el (set-temporary-overlay-map): Minimize slightly the impact of
the temporary map re-appearing on emulation-mode-map-alists.
* emacs-lisp/edebug.el (def-edebug-form-spec): Remove, it's been broken
since 22.1.
* ehelp.el (with-electric-help): Accept functions in
electric-help-form-to-execute.
(electric-help-execute-extended, electric-help-ctrl-x-prefix): Use it.
And replace unread-command-char -> unread-command-events.
2012-09-12 Michael Albinus <michael.albinus@gmx.de>
Sync with Tramp 2.2.6.
* net/tramp.el (tramp-accept-process-output): Don't use
JUST-THIS-ONE in the XEmacs case.
* net/trampver.el: Update release number.
2012-09-12 Martin Rudalics <rudalics@gmx.at>
* emacs-lisp/debug.el (debugger-previous-window-height):
New variable.
(debug): When debugger-jumping-flag is non-nil try to restore
height of debugger window. (Bug#8789)
2012-09-12 Stefan Monnier <monnier@iro.umontreal.ca>
* emacs-lisp/edebug.el (edebug-enter): Don't mess with
overriding-local-map and pre/post-command-hook here.
(edebug-recursive-edit): Do it here instead (bug#12345).
(edebug-outside-unread-command-char): Remove all uses of
unread-command-char.
* emacs-lisp/debug.el (debug): Don't bind debug-on-error since
inhibit-debugger is bound instead.
2012-09-11 Bastien Guerry <bzg@gnu.org>
* subr.el (set-temporary-overlay-map): Add a docstring.
(Bug#12346)
2012-09-11 Bastien Guerry <bzg@gnu.org>
* minibuffer.el (completion-table-subvert): Fix docstring.
(Bug#12347)
2012-09-11 Bastien Guerry <bzg@gnu.org>
* help-fns.el (describe-variable): Fix typo. (Bug#12346)
2012-09-10 Michael R. Mauger <mmaug@yahoo.com>
* progmodes/sql.el: Version 3.1
(sql-db2-escape-newlines): New variable.
(sql-escape-newlines-filter): Use it.
2012-09-10 Juanma Barranquero <lekktu@gmail.com>
* custom.el (custom-theme-load-confirm): Remove unneeded assignment.
2012-09-10 Dan Nicolaescu <dann@gnu.org>
* vc/diff-mode.el (diff-mode-menu):
Bind diff-remove-trailing-whitespace.
2012-09-10 Stefan Monnier <monnier@iro.umontreal.ca>
* emacs-lisp/lisp-mode.el (emacs-list-byte-code-comment-re): New var.
(emacs-lisp-byte-code-comment, emacs-lisp-byte-code-syntax-propertize)
(emacs-lisp-byte-code-mode): New functions.
(eval-sexp-add-defvars): Don't skip defvars in column >0.
(eval-defun-2): Remove bogus interactive spec.
(lisp-indent-line): Remove redundant whole-exp code, now done in
indent-according-to-mode.
(save-match-data): Remove redundant indent data.
* emacs-lisp/benchmark.el (benchmark-run, benchmark-run-compiled):
Use `declare'.
2012-09-09 Juri Linkov <juri@jurta.org>
* replace.el (replace-regexp-lax-whitespace): New defcustom.
(replace-lax-whitespace, query-replace-regexp)
(query-replace-regexp-eval, replace-regexp): Doc fix.
(perform-replace, replace-highlight): Let-bind
isearch-lax-whitespace to replace-lax-whitespace and
isearch-regexp-lax-whitespace to replace-regexp-lax-whitespace.
* isearch.el (isearch-query-replace): Let-bind
replace-lax-whitespace to isearch-lax-whitespace and
replace-regexp-lax-whitespace to
isearch-regexp-lax-whitespace. (Bug#10885)
2012-09-09 Stefan Monnier <monnier@iro.umontreal.ca>
* eshell/em-unix.el (eshell/sudo): Explicitly drop return value.
2012-09-09 Alan Mackenzie <acm@muc.de>
* progmodes/cc-engine.el (c-state-cache-init):
Initialise c-state-semi-nonlit-pos-cache\(-limit\)? properly.
(c-record-parse-state-state):
Record c-state-semi-nonlit-pos-cache\(-limit\)?.
2012-09-09 Andreas Schwab <schwab@linux-m68k.org>
* register.el (register-separator): Rename from
separator-register. All uses changed. Doc fix.
(register): Fix version.
2012-09-09 Chong Yidong <cyd@gnu.org>
* replace.el (query-replace-map): Bind four new symbols for
requesting window scrolling.
* subr.el (y-or-n-p): Handle the window-scrolling bindings in
query-replace-map (Bug#8948).
* custom.el (custom-theme-load-confirm): Use y-or-n-p.
* emacs-lisp/map-ynp.el (map-y-or-n-p): Don't bind scrolling keys
since they are now in query-replace-map.
* window.el (scroll-other-window-down): Make the arg optional.
2012-09-09 Chong Yidong <cyd@gnu.org>
* files.el (hack-local-variables-confirm): Use quit-window to kill
the *Local Variables* buffer.
2012-09-08 Dmitry Gutov <dgutov@yandex.ru>
* progmodes/ruby-mode.el (ruby-toggle-block): Guess the current block,
not just expect to be at its beginning. Adjust callees.
Succeed when do-end block has no space before the pipe character.
(ruby-brace-to-do-end): When the original block is one-liner,
convert to multiline. Reindent the result.
2012-09-08 Jambunathan K <kjambunathan@gmail.com>
* register.el (register): New group.
(register-separator): New user option.
(increment-register): Route it to `append-to-register', if
register contains text. Implication is that `C-x r +' can now be
used for appending to a text register (bug#12217).
(append-to-register, prepend-to-register): Add separator based on
`register-separator.
2012-09-08 Alan Mackenzie <acm@muc.de>
AWK Mode: make auto-newline work when there's "==" in the pattern.
* progmodes/cc-cmds.el (c-point-syntax): Handle virtual semicolons
correctly.
* progmodes/cc-engine.el (c-guess-basic-syntax CASE 5A.3):
Test more rigorously for "=" token.
2012-09-08 Dmitry Gutov <dgutov@yandex.ru>
* progmodes/ruby-mode.el (ruby-match-expression-expansion):
Only fail when reached LIMIT.
2012-09-08 Chong Yidong <cyd@gnu.org>
* dired.el (dired-mode-map): Don't bind M-=.
* dired-aux.el (dired-diff): Use backup file as default.
2012-09-08 Drew Adams <drew.adams@oracle.com>
* subr.el (add-to-history): Fix delete usage (Bug#12314).
2012-09-08 Chong Yidong <cyd@gnu.org>
* subr.el (syntax-after, syntax-class): Doc fix.
2012-09-08 Martin Rudalics <rudalics@gmx.at>
* window.el (display-buffer-in-previous-window): New buffer
display action function.
* emacs-lisp/debug.el (debugger-bury-or-kill): New option.
(debugger-previous-window): New variable.
(debug): Rewrite using display-buffer-in-previous-window,
quit-restore-window and debugger-bury-or-kill. (Bug#8789)
2012-09-07 Stefan Monnier <monnier@iro.umontreal.ca>
* emacs-lisp/byte-run.el (defun): Tweak message. Simplify code.
2012-09-07 Matt McClure <mlm@aya.yale.edu> (tiny change)
* progmodes/python.el (python-shell-send-string):
When default-directory is remote, create temp file on remote
filesystem.
(python-shell-send-file): When file is remote, pass local view of
file paths to remote Python interpreter. (Bug#12340)
2012-09-07 Chong Yidong <cyd@gnu.org>
* window.el (switch-to-buffer): Doc fix (Bug#12181).
* files.el (after-find-file): Don't fail on a read-only buffer if
require-final-newline is `visit' or `visit-save' (Bug#11156).
* subr.el (read-char-choice): Allow quitting via ESC ESC.
* userlock.el (ask-user-about-supersession-threat):
Use read-char-choice (Bug#12093).
2012-09-07 Chong Yidong <cyd@gnu.org>
* subr.el (buffer-narrowed-p): New function.
* ses.el (ses-widen):
* simple.el (count-words--buffer-message):
* net/browse-url.el (browse-url-of-buffer): Use it
* simple.el (count-words-region): Don't signal an error if there
is a non-nil prefix arg and the mark is not set.
* help.el (describe-key-briefly): Allow the message to be seen
when invoked from the minibuffer (Bug#7014).
2012-09-07 Dmitry Gutov <dgutov@yandex.ru>
* progmodes/ruby-mode.el (ruby-end-of-defun)
(ruby-beginning-of-defun): Simplify, allow indentation before
block beginning and end keywords.
(ruby-beginning-of-defun): Only consider 3 keywords defun beginners.
(ruby-end-of-defun): Expect that the point is at the beginning of
the defun.
2012-09-06 Stefan Monnier <monnier@iro.umontreal.ca>
* emacs-lisp/cl-macs.el (cl--do-arglist): Understand _ on &key args
(bug#12367).
(cl--make-usage-args): Strip _ from argument names.
2012-09-06 Rüdiger Sonderfeld <ruediger@c-plusplus.de>
* progmodes/vhdl-mode.el (vhdl-speedbar-initialize): Don't use
obsolete alias speedbar-key-map.
(vhdl-doc-variable, vhdl-doc-mode): Use called-interactively-p.
(vhdl-index-menu-init): Don't use obsolete variable
font-lock-maximum-size.
2012-09-06 Chong Yidong <cyd@gnu.org>
* frame.el (window-system-version): Mark as obsolete.
* speedbar.el (speedbar-update-flag, speedbar-mode): Remove uses
of obsolete variable speedbar-key-map.
2012-09-06 Juri Linkov <juri@jurta.org>
* replace.el (replace-lax-whitespace): New defcustom.
(query-replace, query-replace-regexp, query-replace-regexp-eval)
(replace-string, replace-regexp): Mention it in docstrings.
(perform-replace, replace-highlight): Let-bind
isearch-lax-whitespace and isearch-regexp-lax-whitespace according
to the values of replace-lax-whitespace and regexp-flag.
Don't let-bind search-whitespace-regexp. (Bug#10885)
* isearch.el (isearch-query-replace): Let-bind
replace-lax-whitespace instead of let-binding
replace-search-function and replace-re-search-function.
(isearch-lazy-highlight-search): Let-bind isearch-lax-whitespace
and isearch-regexp-lax-whitespace to lazy-highlight variables.
(isearch-toggle-symbol): Set isearch-regexp to nil
in isearch-word mode (like in isearch-toggle-word).
2012-09-06 Juri Linkov <juri@jurta.org>
* replace.el (replace-search-function)
(replace-re-search-function): Set default values to nil.
(perform-replace): Let-bind isearch-related variables based on
replace-related values, call `isearch-search-fun' and let-bind
the result to `search-function'. Remove code that sets
`search-function' and `search-string' separately for
`delimited-flag'.
(replace-highlight): Add new argument `delimited-flag' and
rename other arguments to the names used in `perform-replace'.
Let-bind `isearch-word' to the argument `delimited-flag'.
(Bug#10885, bug#10887)
2012-09-07 Dmitry Gutov <dgutov@yandex.ru>
* progmodes/ruby-mode.el (ruby-indent-beg-re): Add pieces from
ruby-beginning-of-indent, simplify, allow all keywords to have
indentation before them.
(ruby-beginning-of-indent): Adjust for above. Search until the
found point is not inside a string or comment.
(ruby-font-lock-keywords): Allow symbols to start with "@"
character, give them higher priority than variables.
(ruby-syntax-propertize-function)
(ruby-font-lock-syntactic-keywords): Remove the "not comments"
matchers. Expression expansions are not comments when inside a
string, and there comment syntax status is irrelevant.
(ruby-match-expression-expansion): New function. Check that
expression expansion is inside a string, and it's not escaped.
(ruby-font-lock-keywords): Use it.
2012-09-05 Martin Rudalics <rudalics@gmx.at>
* help.el (temp-buffer-max-height): New default value.
(temp-buffer-resize-frames): New option.
(resize-temp-buffer-window): Optionally resize frame.
* window.el (fit-frame-to-buffer-bottom-margin): New option.
(fit-frame-to-buffer): New function.
2012-09-05 Glenn Morris <rgm@gnu.org>
* emulation/cua-rect.el (cua--init-rectangles):
* textmodes/picture.el (picture-mode-map):
* play/blackbox.el (blackbox-mode-map): Remap right-char and left-char
like forward-char and backward-char. (Bug#12317)
2012-09-05 Leo Liu <sdl.web@gmail.com>
* progmodes/flymake.el (flymake-warning-re): New variable.
(flymake-parse-line): Use it.
2012-09-05 Glenn Morris <rgm@gnu.org>
* calendar/holidays.el (holiday-christian-holidays):
Rename an entry. (Bug#12289)
2012-09-05 Stefan Monnier <monnier@iro.umontreal.ca>
* progmodes/sh-script.el (sh-font-lock-paren): Don't burp at BOB
(bug#12222).
2012-09-04 Stefan Monnier <monnier@iro.umontreal.ca>
* loadup.el: Load macroexp. Remove hack.
* emacs-lisp/macroexp.el (macroexp--eval-if-compile): New function.
(macroexp--expand-all): Use it to get better warnings.
(macroexp--backtrace, macroexp--trim-backtrace-frame)
(internal-macroexpand-for-load): New functions.
(macroexp--pending-eager-loads): New var.
(emacs-startup-hook): New hack to replace one in loadup.el.
* emacs-lisp/cl-macs.el (cl--compiler-macro-list*)
(cl--compiler-macro-cXXr): Move to top, before they can be used.
(cl-psetf): Simplify.
(cl-defstruct): Add indent rule.
2012-09-04 Lars Ingebrigtsen <larsi@gnus.org>
* mail/smtpmail.el (smtpmail-send-it): Prefer the From: header
over `user-mail-address' for the SMTP MAIL FROM envelope.
(smtpmail-via-smtp): Ditto.
2012-09-04 Dmitry Gutov <dgutov@yandex.ru>
* progmodes/ruby-mode.el: Clean up keybindings.
(ruby-mode-map): Don't bind ruby-electric-brace,
ruby-beginning-of-defun, ruby-end-of-defun, ruby-mark-defun,
backward-kill-word, reindent-then-newline-and-indent.
(ruby-mark-defun): Remove.
(ruby-electric-brace): Remove. Obsoleted by electric-indent-chars.
(ruby-mode): Set local beginning-of-defun-function and
end-of-defun-function values.
2012-09-03 Martin Rudalics <rudalics@gmx.at>
* window.el (temp-buffer-window-setup-hook)
(temp-buffer-window-show-hook): New hooks.
(temp-buffer-window-setup, temp-buffer-window-show)
(with-temp-buffer-window): New functions.
(fit-window-to-buffer): Remove unused optional argument OVERRIDE.
(special-display-popup-frame): Make sure the window used shows BUFFER.
* help.el (temp-buffer-resize-mode): Fix doc-string.
(resize-temp-buffer-window): New optional argument WINDOW.
* files.el (recover-file, save-buffers-kill-emacs):
* dired.el (dired-mark-pop-up): Use with-temp-buffer-window.
2012-09-02 Michael Albinus <michael.albinus@gmx.de>
* eshell/em-unix.el (eshell/sudo): When we have an ad-hoc
@ -132,8 +728,8 @@
2012-08-29 Michael Albinus <michael.albinus@gmx.de>
* eshell/esh-ext.el (eshell-external-command): Do not examine
remote shell scripts. See
<https://bugs.launchpad.net/ubuntu/+source/emacs23/+bug/1035790>.
remote shell scripts.
See <https://bugs.launchpad.net/ubuntu/+source/emacs23/+bug/1035790>.
* net/tramp-sh.el (tramp-remote-path): Add "/sbin" and
"/usr/local/sbin".
@ -1175,7 +1771,7 @@
* calc-mode.el (calc-basic-simplification-mode): Rename from
`calc-limited-simplification-mode'.
(calc-alg-simplification-mode): New function.
(calc-set-simplify-mode): Adjust message.
(calc-set-simplify-mode): Adjust message.
* calc.el (calc-set-mode-line): Adjust mode line display for
basic simplification mode.
@ -1373,7 +1969,7 @@
* notifications.el (notifications-on-action-signal)
(notifications-on-closed-signal): Use also the bus address for the map.
(notifications-notify, notifications-close-notification)
(notifications-get-capabilities): Add optional argument BUS.
(notifications-get-capabilities): Add optional argument BUS.
2012-07-27 Tassilo Horn <tsdh@gnu.org>
@ -1493,7 +2089,7 @@
ses-cell-set-formula or ses-set-cell to change the cell and handle
the undo at the same time, but rather use lower level new macros
`ses-cell-formula-aset' and `ses-cell-references-aset' and handle
the undo directly. Refresh the mode line.
the undo directly. Refresh the mode line.
2012-07-21 Leo Liu <sdl.web@gmail.com>
@ -4909,13 +5505,13 @@
* progmodes/verilog-mode.el (font-lock-keywords):
Fix mis-highligting auto. Reported by Craig Barner.
(verilog-auto, verilog-auto-undef): Add AUTOUNDEF to remove
defines from global name space. Reported by Dan Dever.
defines from global name space. Reported by Dan Dever.
(verilog-auto-reset, verilog-auto-reset-widths)
(verilog-auto-tieoff): Support using unbased numbers for
AUTORESET and AUTOTIEOFF.
(verilog-submit-bug-report): Update variable list.
(verilog-read-auto-params): Fix AUTOINPUT regexps containing
parenthesis from not matching. Reported by Michael Rytting.
parenthesis from not matching. Reported by Michael Rytting.
(verilog-auto-template-lint): Fix hash error when linting modules
with no used templates.
(verilog-warn, verilog-warn-error)
@ -4925,12 +5521,12 @@
(verilog-read-auto-template): Add `verilog-auto-template-warn-unused'
to report unused template errors. Reported by Brad Dobbie.
(verilog-read-decls): Fix AUTOWIRE etc on supply0, supply1 type
nets, bug438. Reported by Vns Blore.
nets, bug438. Reported by Vns Blore.
(verilog-auto-inout-module, verilog-auto-reg)
(verilog-read-decls, verilog-read-sub-decls-sig)
(verilog-signals-edit-wire-reg, verilog-signals-with):
Fix passing of Verilog data types in ANSI input/output ports
such as "output logic" into the AUTOs. Special case "wire" and
such as "output logic" into the AUTOs. Special case "wire" and
"reg" for backwards compatibility presuming Verilog 2001.
(verilog-auto-ascii-enum): Add "auto enum" as alias.
(verilog-preprocess): Fix replication of preprocess output.
@ -4951,7 +5547,7 @@
(verilog-read-decls): Fix 'parameter type' not appearing in
AUTOINSTPARAM, bug340. Reported by Jonathan Greenlaw.
(verilog-auto-logic): Fix when AUTOLOGIC present to properly do
AUTOINPUTs, bug411. Reported by Jonathan Greenlaw.
AUTOINPUTs, bug411. Reported by Jonathan Greenlaw.
(verilog-read-auto-lisp): Avoid syntax-ppss warning on AUTOLISP.
Reported by David Kravitz.

View file

@ -74,7 +74,7 @@
;; align-?-modes variables (for example, `align-dq-string-modes'), use
;; `add-to-list', or some similar function which checks first to see
;; if the value is already there. Since the user may customize that
;; mode list, and then write your mode name into their .emacs file,
;; mode list, and then write your mode name into their init file,
;; causing the symbol already to be present the next time they load
;; your package.
@ -1201,7 +1201,10 @@ have been aligned. No changes will be made to the buffer."
(gocol col) cur)
(when area
(if func
(funcall func (car area) (cdr area) change)
(funcall func
(marker-position (car area))
(marker-position (cdr area))
change)
(if (not (and justify
(consp (cdr area))))
(goto-char (cdr area))

View file

@ -36,7 +36,7 @@
;; setq auto-insert-directory to an appropriate slash-terminated value
;;
;; You can also customize the variable `auto-insert-mode' to load the
;; package. Alternatively, add the following to your .emacs file:
;; package. Alternatively, add the following to your init file:
;; (auto-insert-mode 1)
;;
;; Author: Charlie Martin

View file

@ -144,10 +144,7 @@ You can toggle whether files are shown with \\<bookmark-bmenu-mode-map>\\[bookma
(defcustom bookmark-bmenu-toggle-filenames t
"Non-nil means show filenames when listing bookmarks.
This may result in truncated bookmark names. To disable this, put the
following in your `.emacs' file:
\(setq bookmark-bmenu-toggle-filenames nil)"
A non-nil value may result in truncated bookmark names."
:type 'boolean
:group 'bookmark)

View file

@ -61,7 +61,7 @@
(declare-function math-vector-is-string "calccomp" (a))
(declare-function math-vector-to-string "calccomp" (a &optional quoted))
(declare-function math-format-radix-float "calc-bin" (a prec))
(declare-function math-compose-expr "calccomp" (a prec))
(declare-function math-compose-expr "calccomp" (a prec &optional div))
(declare-function math-abs "calc-arith" (a))
(declare-function math-format-bignum-binary "calc-bin" (a))
(declare-function math-format-bignum-octal "calc-bin" (a))
@ -3483,7 +3483,7 @@ If X is not an error form, return 1."
(substring str i))))
str))
;;; Users can redefine this in their .emacs files.
;;; Users can redefine this in their init files.
(defvar calc-keypad-user-menu nil
"If non-nil, this describes an additional menu for calc-keypad.
It should contain a list of three rows.

View file

@ -494,7 +494,7 @@
(car res))))))))
;;; It is safe to redefine these in your .emacs file to use a different
;;; It is safe to redefine these in your init file to use a different
;;; language.
(defvar math-long-weekday-names '( "Sunday" "Monday" "Tuesday" "Wednesday"

View file

@ -199,7 +199,7 @@
(declare-function calc-div-fractions "calc-frac" (a b))
(declare-function math-div-objects-fancy "calc-arith" (a b))
(declare-function math-div-symb-fancy "calc-arith" (a b))
(declare-function math-compose-expr "calccomp" (a prec))
(declare-function math-compose-expr "calccomp" (a prec &optional div))
(declare-function math-comp-width "calccomp" (c))
(declare-function math-composition-to-string "calccomp" (c &optional width))
(declare-function math-stack-value-offset-fancy "calccomp" ())

View file

@ -593,7 +593,7 @@ You can customize `diary-date-forms' to your preferred format.
Three default styles are provided: `diary-american-date-forms',
`diary-european-date-forms', and `diary-iso-date-forms'.
You can choose between these by setting `calendar-date-style' in your
.emacs file, or by using `calendar-set-date-style' when in the calendar.
init file, or by using `calendar-set-date-style' when in the calendar.
A diary entry can be preceded by the character `diary-nonmarking-symbol'
\(ordinarily `&') to make that entry nonmarking--that is, it will not be
@ -1276,7 +1276,7 @@ Runs the following hooks:
generating a calendar, if today's date is visible or not, respectively
`calendar-initial-window-hook' - after first creating a calendar
This function is suitable for execution in a .emacs file."
This function is suitable for execution in an init file."
(interactive "P")
;; Avoid loading cal-x unless it will be used.
(if (and (memq calendar-setup '(one-frame two-frames calendar-only))

View file

@ -200,19 +200,21 @@ holidays), or hard copy output."
'diary-list-entries-hook "23.1")
(defcustom diary-list-entries-hook nil
"List of functions called after diary file is culled for relevant entries.
You might wish to add `diary-include-other-diary-files', in which case
you will probably also want to add `diary-mark-included-diary-files' to
`diary-mark-entries-hook'. For example, you could use
"Hook run after diary file is culled for relevant entries.
If you add `diary-include-other-diary-files' to this hook, you
will probably also want to add `diary-mark-included-diary-files'
to `diary-mark-entries-hook'. For example, to cause the fancy
diary buffer to be displayed with diary entries from various
included files, each day's entries sorted into lexicographic
order, add the following to your init file:
(setq diary-display-function 'diary-fancy-display)
(add-hook 'diary-list-entries-hook 'diary-include-other-diary-files)
(add-hook 'diary-list-entries-hook 'diary-sort-entries t)
in your `.emacs' file to cause the fancy diary buffer to be displayed with
diary entries from various included files, each day's entries sorted into
lexicographic order. Note how the sort function is placed last,
so that it can sort the entries included from other files.
Note how the sort function is placed last, so that it can sort
the entries included from other files.
This hook runs after `diary-nongregorian-listing-hook'. These two hooks
differ only if you are using included diary files. In that case,
@ -532,7 +534,7 @@ If so, return the expanded file name, otherwise signal an error."
"Generate the diary window for ARG days starting with the current date.
If no argument is provided, the number of days of diary entries is governed
by the variable `diary-number-of-entries'. A value of ARG less than 1
does nothing. This function is suitable for execution in a `.emacs' file."
does nothing. This function is suitable for execution in an init file."
(interactive "P")
(diary-check-diary-file)
(diary-list-entries (calendar-current-date)
@ -1230,8 +1232,8 @@ Mail is sent to the address specified by `diary-mail-addr'.
Here is an example of a script to call `diary-mail-entries',
suitable for regular scheduling using cron (or at). Note that
since `emacs -script' does not load your `.emacs' file, you
should ensure that all relevant variables are set.
since `emacs -script' does not load your init file, you should
ensure that all relevant variables are set.
#!/usr/bin/emacs -script
;; diary-rem.el - run the Emacs diary-reminder

View file

@ -250,7 +250,7 @@ See the documentation for `calendar-holidays' for details."
(if calendar-christian-all-holidays-flag
(append
(holiday-fixed 1 6 "Epiphany")
(holiday-julian 12 25 "Eastern Orthodox Christmas")
(holiday-julian 12 25 "Christmas (Julian calendar)")
(holiday-greek-orthodox-easter)
(holiday-fixed 8 15 "Assumption")
(holiday-advent 0 "Advent")))))
@ -343,12 +343,12 @@ See the documentation for `calendar-holidays' for details."
"List of notable days for the command \\[holidays].
Additional holidays are easy to add to the list, just put them in the
list `holiday-other-holidays' in your .emacs file. Similarly, by setting
list `holiday-other-holidays' in your init file. Similarly, by setting
any of `holiday-general-holidays', `holiday-local-holidays',
`holiday-christian-holidays', `holiday-hebrew-holidays',
`holiday-islamic-holidays', `holiday-bahai-holidays',
`holiday-oriental-holidays', or `holiday-solar-holidays' to nil in your
.emacs file, you can eliminate unwanted categories of holidays.
init file, you can eliminate unwanted categories of holidays.
The aforementioned variables control the holiday choices offered
by the function `holiday-list' when it is called interactively.
@ -523,7 +523,7 @@ use instead of point."
(defun holidays (&optional arg)
"Display the holidays for last month, this month, and next month.
If called with an optional prefix argument ARG, prompts for month and year.
This function is suitable for execution in a .emacs file."
This function is suitable for execution in a init file."
(interactive "P")
(save-excursion
(let* ((completion-ignore-case t)

View file

@ -236,7 +236,7 @@ use instead of point."
(defun lunar-phases (&optional arg)
"Display the quarters of the moon for last month, this month, and next month.
If called with an optional prefix argument ARG, prompts for month and year.
This function is suitable for execution in a .emacs file."
This function is suitable for execution in an init file."
(interactive "P")
(save-excursion
(let* ((date (if arg (calendar-read-date t)

View file

@ -797,7 +797,7 @@ If called with an optional prefix argument ARG, prompt for date.
If called with an optional double prefix argument, prompt for
longitude, latitude, time zone, and date, and always use standard time.
This function is suitable for execution in a .emacs file."
This function is suitable for execution in an init file."
(interactive "p")
(or arg (setq arg 1))
(if (and (< arg 16)

View file

@ -49,7 +49,7 @@
;; If you want Emacs to display the amount of time "left" to your
;; workday in the mode-line, you can either set the value of
;; `timeclock-mode-line-display' to t using M-x customize, or you can
;; add this code to your .emacs file:
;; add this code to your init file:
;;
;; (require 'timeclock)
;; (timeclock-mode-line-display)
@ -60,7 +60,7 @@
;; You may also want Emacs to ask you before exiting, if you are
;; currently working on a project. This can be done either by setting
;; `timeclock-ask-before-exiting' to t using M-x customize (this is
;; the default), or by adding the following to your .emacs file:
;; the default), or by adding the following to your init file:
;;
;; (add-hook 'kill-emacs-query-functions 'timeclock-query-out)

View file

@ -181,7 +181,7 @@ override the read-only-ness of comint prompts is to call
`comint-kill-whole-line' or `comint-kill-region' with no
narrowing in effect. This way you will be certain that none of
the remaining prompts will be accidentally messed up. You may
wish to put something like the following in your `.emacs' file:
wish to put something like the following in your init file:
\(add-hook 'comint-mode-hook
(lambda ()

View file

@ -237,7 +237,7 @@ The following keywords are meaningful:
is `default-value'.
:require
VALUE should be a feature symbol. If you save a value
for this option, then when your `.emacs' file loads the value,
for this option, then when your init file loads the value,
it does (require VALUE) first.
:set-after VARIABLES
Specifies that SYMBOL should be set after the list of variables
@ -1223,38 +1223,19 @@ Return t if THEME was successfully loaded, nil otherwise."
"Query the user about loading a Custom theme that may not be safe.
The theme should be in the current buffer. If the user agrees,
query also about adding HASH to `custom-safe-themes'."
(if noninteractive
nil
(let ((exit-chars '(?y ?n ?\s))
window prompt char)
(save-window-excursion
(rename-buffer "*Custom Theme*" t)
(emacs-lisp-mode)
(setq window (display-buffer (current-buffer)))
(setq prompt
(format "Loading a theme can run Lisp code. Really load?%s"
(if (and window
(< (line-number-at-pos (point-max))
(window-body-height)))
" (y or n) "
(push ?\C-v exit-chars)
"\nType y or n, or C-v to scroll: ")))
(goto-char (point-min))
(while (null char)
(setq char (read-char-choice prompt exit-chars))
(when (eq char ?\C-v)
(if window
(with-selected-window window
(condition-case nil
(scroll-up)
(error (goto-char (point-min))))))
(setq char nil)))
(when (memq char '(?\s ?y))
;; Offer to save to `custom-safe-themes'.
(and (or custom-file user-init-file)
(y-or-n-p "Treat this theme as safe in future sessions? ")
(customize-push-and-save 'custom-safe-themes (list hash)))
t)))))
(unless noninteractive
(save-window-excursion
(rename-buffer "*Custom Theme*" t)
(emacs-lisp-mode)
(pop-to-buffer (current-buffer))
(goto-char (point-min))
(prog1 (when (y-or-n-p "Loading a theme can run Lisp code. Really load? ")
;; Offer to save to `custom-safe-themes'.
(and (or custom-file user-init-file)
(y-or-n-p "Treat this theme as safe in future sessions? ")
(customize-push-and-save 'custom-safe-themes (list hash)))
t)
(quit-window)))))
(defun custom-theme-name-valid-p (name)
"Return t if NAME is a valid name for a Custom theme, nil otherwise.

View file

@ -34,7 +34,7 @@
;; - some local variables
;; To use this, use customize to turn on desktop-save-mode or add the
;; following line somewhere in your .emacs file:
;; following line somewhere in your init file:
;;
;; (desktop-save-mode 1)
;;

View file

@ -54,43 +54,30 @@ into this list; they also should call `dired-log' to log the errors.")
;;;###autoload
(defun dired-diff (file &optional switches)
"Compare file at point with file FILE using `diff'.
FILE defaults to the file at the mark. (That's the mark set by
\\[set-mark-command], not by Dired's \\[dired-mark] command.)
The prompted-for FILE is the first file given to `diff'.
If called interactively, prompt for FILE; if the file at point
has a backup file, use that as the default.
FILE is the first file given to `diff'.
With prefix arg, prompt for second argument SWITCHES,
which is the string of command switches for `diff'."
(interactive
(let* ((current (dired-get-filename t))
;; Get the file at the mark.
(file-at-mark (if (mark t)
(save-excursion (goto-char (mark t))
(dired-get-filename t t))))
;; Use it as default if it's not the same as the current file,
;; and the target dir is the current dir or the mark is active.
(default (if (and (not (equal file-at-mark current))
(or (equal (dired-dwim-target-directory)
(dired-current-directory))
mark-active))
file-at-mark))
(target-dir (if default
(dired-current-directory)
(dired-dwim-target-directory)))
(defaults (dired-dwim-target-defaults (list current) target-dir)))
(require 'diff)
(list
(minibuffer-with-setup-hook
(lambda ()
(set (make-local-variable 'minibuffer-default-add-function) nil)
(setq minibuffer-default defaults))
(read-file-name
(format "Diff %s with%s: " current
(if default (format " (default %s)" default) ""))
target-dir default t))
(if current-prefix-arg
(read-string "Options for diff: "
(if (stringp diff-switches)
diff-switches
(mapconcat 'identity diff-switches " ")))))))
(oldf (file-newest-backup current))
(dir (if oldf (file-name-directory oldf))))
(list (read-file-name
(format "Diff %s with%s: "
(file-name-nondirectory current)
(if oldf
(concat " (default "
(file-name-nondirectory oldf)
")")
""))
dir oldf t)
(if current-prefix-arg
(read-string "Options for diff: "
(if (stringp diff-switches)
diff-switches
(mapconcat 'identity diff-switches " ")))))))
(let ((current (dired-get-filename t)))
(when (or (equal (expand-file-name file)
(expand-file-name current))
@ -257,7 +244,10 @@ List has a form of (file-name full-file-name (attribute-list))."
(function dired-check-process)
(append
(list operation program)
(unless (string-equal new-attribute "")
(unless (or (string-equal new-attribute "")
;; Use `eq' instead of `equal'
;; to detect empty input (bug#12399).
(eq new-attribute default))
(if (eq op-symbol 'touch)
(list "-t" new-attribute)
(list new-attribute)))
@ -291,7 +281,10 @@ Symbolic modes like `g+w' are allowed."
"Change mode of %s to: "
nil 'chmod arg files default))
num-modes)
(cond ((equal modes "")
(cond ((or (equal modes "")
;; Use `eq' instead of `equal'
;; to detect empty input (bug#12399).
(eq modes default))
;; We used to treat empty input as DEFAULT, but that is not
;; such a good idea (Bug#9361).
(error "No file mode specified"))

View file

@ -1410,7 +1410,6 @@ Do so according to the former subdir alist OLD-SUBDIR-ALIST."
(define-key map "&" 'dired-do-async-shell-command)
;; Comparison commands
(define-key map "=" 'dired-diff)
(define-key map "\M-=" 'dired-backup-diff)
;; Tree Dired commands
(define-key map "\M-\C-?" 'dired-unmark-all-files)
(define-key map "\M-\C-d" 'dired-tree-down)
@ -2973,36 +2972,43 @@ If t, confirmation is never needed."
(const shell) (const symlink) (const touch)
(const uncompress))))
(defun dired-mark-pop-up (bufname op-symbol files function &rest args)
(defun dired-mark-pop-up (buffer-or-name op-symbol files function &rest args)
"Return FUNCTION's result on ARGS after showing which files are marked.
Displays the file names in a buffer named BUFNAME;
nil gives \" *Marked Files*\".
This uses function `dired-pop-to-buffer' to do that.
Displays the file names in a window showing a buffer named
BUFFER-OR-NAME; the default name being \" *Marked Files*\". The
window is not shown if there is just one file, `dired-no-confirm'
is t, or OP-SYMBOL is a member of the list in `dired-no-confirm'.
FUNCTION should not manipulate files, just read input
(an argument or confirmation).
The window is not shown if there is just one file or
OP-SYMBOL is a member of the list in `dired-no-confirm'.
FILES is the list of marked files. It can also be (t FILENAME)
in the case of one marked file, to distinguish that from using
just the current file."
(or bufname (setq bufname " *Marked Files*"))
just the current file.
FUNCTION should not manipulate files, just read input \(an
argument or confirmation)."
(if (or (eq dired-no-confirm t)
(memq op-symbol dired-no-confirm)
;; If FILES defaulted to the current line's file.
(= (length files) 1))
(apply function args)
(with-current-buffer (get-buffer-create bufname)
(erase-buffer)
;; Handle (t FILE) just like (FILE), here.
;; That value is used (only in some cases), to mean
;; just one file that was marked, rather than the current line file.
(dired-format-columns-of-files (if (eq (car files) t) (cdr files) files))
(remove-text-properties (point-min) (point-max)
'(mouse-face nil help-echo nil)))
(save-window-excursion
(dired-pop-to-buffer bufname)
(apply function args))))
(let ((buffer (get-buffer-create (or buffer-or-name " *Marked Files*"))))
(with-current-buffer buffer
(let ((split-height-threshold 0))
(with-temp-buffer-window
buffer
(cons 'display-buffer-below-selected nil)
#'(lambda (window _value)
(with-selected-window window
(unwind-protect
(apply function args)
(when (window-live-p window)
(quit-restore-window window 'kill)))))
;; Handle (t FILE) just like (FILE), here. That value is
;; used (only in some cases), to mean just one file that was
;; marked, rather than the current line file.
(dired-format-columns-of-files
(if (eq (car files) t) (cdr files) files))
(remove-text-properties (point-min) (point-max)
'(mouse-face nil help-echo nil))))))))
(defun dired-format-columns-of-files (files)
(let ((beg (point)))
@ -3738,14 +3744,15 @@ Ask means pop up a menu for the user to select one of copy, move or link."
;;;;;; dired-run-shell-command dired-do-shell-command dired-do-async-shell-command
;;;;;; dired-clean-directory dired-do-print dired-do-touch dired-do-chown
;;;;;; dired-do-chgrp dired-do-chmod dired-compare-directories dired-backup-diff
;;;;;; dired-diff) "dired-aux" "dired-aux.el" "9499f79f5853da0aa93d26465c7bf3a1")
;;;;;; dired-diff) "dired-aux" "dired-aux.el" "3c768e470d5d053d0049e0286ce38da7")
;;; Generated autoloads from dired-aux.el
(autoload 'dired-diff "dired-aux" "\
Compare file at point with file FILE using `diff'.
FILE defaults to the file at the mark. (That's the mark set by
\\[set-mark-command], not by Dired's \\[dired-mark] command.)
The prompted-for FILE is the first file given to `diff'.
If called interactively, prompt for FILE; if the file at point
has a backup file, use that as the default.
FILE is the first file given to `diff'.
With prefix arg, prompt for second argument SWITCHES,
which is the string of command switches for `diff'.

View file

@ -193,7 +193,9 @@ BUFFER is put back into its original major mode."
(replace-buffer-in-windows buffer)
;; must do this outside of save-window-excursion
(bury-buffer buffer))
(eval electric-help-form-to-execute))))
(if (functionp electric-help-form-to-execute)
(funcall electric-help-form-to-execute)
(eval electric-help-form-to-execute)))))
(defun electric-help-command-loop ()
(catch 'exit
@ -349,14 +351,19 @@ will select it.)"
;; continues with execute-extended-command.
(defun electric-help-execute-extended (_prefixarg)
(interactive "p")
(setq electric-help-form-to-execute '(execute-extended-command nil))
(setq electric-help-form-to-execute
(lambda () (execute-extended-command nil)))
(electric-help-retain))
;; This is to be buond to C-x in ehelp mode. Retains ehelp buffer and then
;; continues with ctrl-x prefix.
(defun electric-help-ctrl-x-prefix (_prefixarg)
(interactive "p")
(setq electric-help-form-to-execute '(progn (message nil) (setq unread-command-char ?\C-x)))
(setq electric-help-form-to-execute
(lambda ()
(message nil)
(setq unread-command-events
(append unread-command-events '(?\C-x)))))
(electric-help-retain))

View file

@ -1,4 +1,4 @@
;;; advice.el --- an overloading mechanism for Emacs Lisp functions
;;; advice.el --- An overloading mechanism for Emacs Lisp functions
;; Copyright (C) 1993-1994, 2000-2012 Free Software Foundation, Inc.
@ -1746,7 +1746,8 @@
(provide 'advice-preload)
;; During a normal load this is a noop:
(require 'advice-preload "advice.el")
(require 'macroexp)
(eval-when-compile (require 'cl-lib))
;; @@ Variable definitions:
;; ========================
@ -1812,54 +1813,6 @@ generates a copy of TREE."
(funcall fUnCtIoN tReE))
(t tReE)))
;; this is just faster than `ad-substitute-tree':
(defun ad-copy-tree (tree)
"Return a copy of the list structure of TREE."
(cond ((consp tree)
(cons (ad-copy-tree (car tree))
(ad-copy-tree (cdr tree))))
(t tree)))
(defmacro ad-dolist (varform &rest body)
"A Common-Lisp-style dolist iterator with the following syntax:
(ad-dolist (VAR INIT-FORM [RESULT-FORM])
BODY-FORM...)
which will iterate over the list yielded by INIT-FORM binding VAR to the
current head at every iteration. If RESULT-FORM is supplied its value will
be returned at the end of the iteration, nil otherwise. The iteration can be
exited prematurely with `(ad-do-return [VALUE])'."
(let ((expansion
`(let ((ad-dO-vAr ,(car (cdr varform)))
,(car varform))
(while ad-dO-vAr
(setq ,(car varform) (car ad-dO-vAr))
,@body
;;work around a backquote bug:
;;(` ((,@ '(foo)) (bar))) => (append '(foo) '(((bar)))) wrong
;;(` ((,@ '(foo)) (, '(bar)))) => (append '(foo) (list '(bar)))
,'(setq ad-dO-vAr (cdr ad-dO-vAr)))
,(car (cdr (cdr varform))))))
;;ok, this wastes some cons cells but only during compilation:
(if (catch 'contains-return
(ad-substitute-tree
(function (lambda (subtree)
(cond ((eq (car-safe subtree) 'ad-dolist))
((eq (car-safe subtree) 'ad-do-return)
(throw 'contains-return t)))))
'identity body)
nil)
`(catch 'ad-dO-eXiT ,expansion)
expansion)))
(defmacro ad-do-return (value)
`(throw 'ad-dO-eXiT ,value))
(if (not (get 'ad-dolist 'lisp-indent-hook))
(put 'ad-dolist 'lisp-indent-hook 1))
;; @@ Save real definitions of subrs used by Advice:
;; =================================================
;; Advice depends on the real, unmodified functionality of various subrs,
@ -1924,16 +1877,16 @@ exited prematurely with `(ad-do-return [VALUE])'."
ad-advised-functions)))
(defmacro ad-do-advised-functions (varform &rest body)
"`ad-dolist'-style iterator that maps over `ad-advised-functions'.
"`dolist'-style iterator that maps over `ad-advised-functions'.
\(ad-do-advised-functions (VAR [RESULT-FORM])
BODY-FORM...)
On each iteration VAR will be bound to the name of an advised function
\(a symbol)."
`(ad-dolist (,(car varform)
`(cl-dolist (,(car varform)
ad-advised-functions
,(car (cdr varform)))
(setq ,(car varform) (intern (car ,(car varform))))
,@body))
(setq ,(car varform) (intern (car ,(car varform))))
,@body))
(if (not (get 'ad-do-advised-functions 'lisp-indent-hook))
(put 'ad-do-advised-functions 'lisp-indent-hook 1))
@ -1948,7 +1901,7 @@ On each iteration VAR will be bound to the name of an advised function
`(put ,function 'ad-advice-info ,advice-info))
(defmacro ad-copy-advice-info (function)
`(ad-copy-tree (get ,function 'ad-advice-info)))
`(copy-tree (get ,function 'ad-advice-info)))
(defmacro ad-is-advised (function)
"Return non-nil if FUNCTION has any advice info associated with it.
@ -2022,8 +1975,8 @@ either t or nil, and DEFINITION should be a list of the form
(defun ad-has-enabled-advice (function class)
"True if at least one of FUNCTION's advices in CLASS is enabled."
(ad-dolist (advice (ad-get-advice-info-field function class))
(if (ad-advice-enabled advice) (ad-do-return t))))
(cl-dolist (advice (ad-get-advice-info-field function class))
(if (ad-advice-enabled advice) (cl-return t))))
(defun ad-has-redefining-advice (function)
"True if FUNCTION's advice info defines at least 1 redefining advice.
@ -2036,14 +1989,14 @@ Redefining advices affect the construction of an advised definition."
(defun ad-has-any-advice (function)
"True if the advice info of FUNCTION defines at least one advice."
(and (ad-is-advised function)
(ad-dolist (class ad-advice-classes nil)
(cl-dolist (class ad-advice-classes nil)
(if (ad-get-advice-info-field function class)
(ad-do-return t)))))
(cl-return t)))))
(defun ad-get-enabled-advices (function class)
"Return the list of enabled advices of FUNCTION in CLASS."
(let (enabled-advices)
(ad-dolist (advice (ad-get-advice-info-field function class))
(dolist (advice (ad-get-advice-info-field function class))
(if (ad-advice-enabled advice)
(push advice enabled-advices)))
(reverse enabled-advices)))
@ -2151,7 +2104,7 @@ function at point for which PREDICATE returns non-nil)."
(ad-do-advised-functions (function)
(if (or (null predicate)
(funcall predicate function))
(ad-do-return function)))
(cl-return function)))
(error "ad-read-advised-function: %s"
"There are no qualifying advised functions")))
(let* ((ad-pReDiCaTe predicate)
@ -2184,9 +2137,9 @@ be returned on empty input (defaults to the first non-empty advice
class of FUNCTION)."
(setq default
(or default
(ad-dolist (class ad-advice-classes)
(cl-dolist (class ad-advice-classes)
(if (ad-get-advice-info-field function class)
(ad-do-return class)))
(cl-return class)))
(error "ad-read-advice-class: `%s' has no advices" function)))
(let ((class (completing-read
(format "%s (default %s): " (or prompt "Class") default)
@ -2255,18 +2208,18 @@ NAME can be a symbol or a regular expression matching part of an advice name.
If CLASS is `any' all valid advice classes will be checked."
(if (ad-is-advised function)
(let (found-advice)
(ad-dolist (advice-class ad-advice-classes)
(cl-dolist (advice-class ad-advice-classes)
(if (or (eq class 'any) (eq advice-class class))
(setq found-advice
(ad-dolist (advice (ad-get-advice-info-field
(cl-dolist (advice (ad-get-advice-info-field
function advice-class))
(if (or (and (stringp name)
(string-match
name (symbol-name
(ad-advice-name advice))))
(eq name (ad-advice-name advice)))
(ad-do-return advice)))))
(if found-advice (ad-do-return found-advice))))))
(cl-return advice)))))
(if found-advice (cl-return found-advice))))))
(defun ad-enable-advice-internal (function class name flag)
"Set enable FLAG of FUNCTION's advices in CLASS matching NAME.
@ -2277,10 +2230,10 @@ considered. The number of changed advices will be returned (or nil if
FUNCTION was not advised)."
(if (ad-is-advised function)
(let ((matched-advices 0))
(ad-dolist (advice-class ad-advice-classes)
(dolist (advice-class ad-advice-classes)
(if (or (eq class 'any) (eq advice-class class))
(ad-dolist (advice (ad-get-advice-info-field
function advice-class))
(dolist (advice (ad-get-advice-info-field
function advice-class))
(cond ((or (and (stringp name)
(string-match
name (symbol-name (ad-advice-name advice))))
@ -2586,11 +2539,6 @@ For that it has to be fbound with a non-autoload definition."
(byte-compile symbol)
(fset function (symbol-function symbol))))))
(defun ad-prognify (forms)
(cond ((<= (length forms) 1)
(car forms))
(t (cons 'progn forms))))
;; @@@ Accessing argument lists:
;; =============================
@ -2868,8 +2816,8 @@ in any of these classes."
(if origdoc (setq paragraphs (list origdoc)))
(unless (eq style 'plain)
(push (concat "This " origtype " is advised.") paragraphs))
(ad-dolist (class ad-advice-classes)
(ad-dolist (advice (ad-get-enabled-advices function class))
(dolist (class ad-advice-classes)
(dolist (advice (ad-get-enabled-advices function class))
(setq advice-docstring
(ad-make-single-advice-docstring advice class style))
(if advice-docstring
@ -2891,24 +2839,24 @@ in any of these classes."
(defun ad-advised-arglist (function)
"Find first defined arglist in FUNCTION's redefining advices."
(ad-dolist (advice (append (ad-get-enabled-advices function 'before)
(cl-dolist (advice (append (ad-get-enabled-advices function 'before)
(ad-get-enabled-advices function 'around)
(ad-get-enabled-advices function 'after)))
(let ((arglist (ad-arglist (ad-advice-definition advice))))
(if arglist
;; We found the first one, use it:
(ad-do-return arglist)))))
(cl-return arglist)))))
(defun ad-advised-interactive-form (function)
"Find first interactive form in FUNCTION's redefining advices."
(ad-dolist (advice (append (ad-get-enabled-advices function 'before)
(cl-dolist (advice (append (ad-get-enabled-advices function 'before)
(ad-get-enabled-advices function 'around)
(ad-get-enabled-advices function 'after)))
(let ((interactive-form
(ad-interactive-form (ad-advice-definition advice))))
(if interactive-form
;; We found the first one, use it:
(ad-do-return interactive-form)))))
(cl-return interactive-form)))))
;; @@@ Putting it all together:
;; ============================
@ -2997,47 +2945,47 @@ and BEFORES, AROUNDS and AFTERS are the lists of advices with which ORIG
should be modified. The assembled function will be returned."
(let (before-forms around-form around-form-protected after-forms definition)
(ad-dolist (advice befores)
(cond ((and (ad-advice-protected advice)
before-forms)
(setq before-forms
`((unwind-protect
,(ad-prognify before-forms)
,@(ad-body-forms
(ad-advice-definition advice))))))
(t (setq before-forms
(append before-forms
(ad-body-forms (ad-advice-definition advice)))))))
(dolist (advice befores)
(cond ((and (ad-advice-protected advice)
before-forms)
(setq before-forms
`((unwind-protect
,(macroexp-progn before-forms)
,@(ad-body-forms
(ad-advice-definition advice))))))
(t (setq before-forms
(append before-forms
(ad-body-forms (ad-advice-definition advice)))))))
(setq around-form `(setq ad-return-value ,orig))
(ad-dolist (advice (reverse arounds))
;; If any of the around advices is protected then we
;; protect the complete around advice onion:
(if (ad-advice-protected advice)
(setq around-form-protected t))
(setq around-form
(ad-substitute-tree
(function (lambda (form) (eq form 'ad-do-it)))
(function (lambda (form) around-form))
(ad-prognify (ad-body-forms (ad-advice-definition advice))))))
(dolist (advice (reverse arounds))
;; If any of the around advices is protected then we
;; protect the complete around advice onion:
(if (ad-advice-protected advice)
(setq around-form-protected t))
(setq around-form
(ad-substitute-tree
(function (lambda (form) (eq form 'ad-do-it)))
(function (lambda (form) around-form))
(macroexp-progn (ad-body-forms (ad-advice-definition advice))))))
(setq after-forms
(if (and around-form-protected before-forms)
`((unwind-protect
,(ad-prognify before-forms)
,(macroexp-progn before-forms)
,around-form))
(append before-forms (list around-form))))
(ad-dolist (advice afters)
(cond ((and (ad-advice-protected advice)
after-forms)
(setq after-forms
`((unwind-protect
,(ad-prognify after-forms)
,@(ad-body-forms
(ad-advice-definition advice))))))
(t (setq after-forms
(append after-forms
(ad-body-forms (ad-advice-definition advice)))))))
(dolist (advice afters)
(cond ((and (ad-advice-protected advice)
after-forms)
(setq after-forms
`((unwind-protect
,(macroexp-progn after-forms)
,@(ad-body-forms
(ad-advice-definition advice))))))
(t (setq after-forms
(append after-forms
(ad-body-forms (ad-advice-definition advice)))))))
(setq definition
`(,@(if (memq type '(macro special-form)) '(macro))
@ -3061,7 +3009,7 @@ should be modified. The assembled function will be returned."
(ad-body-forms (ad-advice-definition advice))))
(ad-get-enabled-advices function hook-name))))
(if hook-forms
(ad-prognify (apply 'append hook-forms)))))
(macroexp-progn (apply 'append hook-forms)))))
;; @@ Caching:
@ -3171,11 +3119,11 @@ advised definition from scratch."
(nth 2 cache-id)))))
(defun ad-verify-cache-class-id (cache-class-id advices)
(ad-dolist (advice advices (null cache-class-id))
(cl-dolist (advice advices (null cache-class-id))
(if (ad-advice-enabled advice)
(if (eq (car cache-class-id) (ad-advice-name advice))
(setq cache-class-id (cdr cache-class-id))
(ad-do-return nil)))))
(cl-return nil)))))
;; There should be a way to monitor if and why a cache verification failed
;; in order to determine whether a certain preactivation could be used or
@ -3670,7 +3618,16 @@ See Info node `(elisp)Advising Functions' for comprehensive documentation.
usage: (defadvice FUNCTION (CLASS NAME [POSITION] [ARGLIST] FLAG...)
[DOCSTRING] [INTERACTIVE-FORM]
BODY...)"
(declare (doc-string 3))
(declare (doc-string 3)
(debug (&define name ;; thing being advised.
(name ;; class is [&or "before" "around" "after"
;; "activation" "deactivation"]
name ;; name of advice
&rest sexp ;; optional position and flags
)
[&optional stringp]
[&optional ("interactive" interactive)]
def-body)))
(if (not (ad-name-p function))
(error "defadvice: Invalid function name: %s" function))
(let* ((class (car args))

View file

@ -53,6 +53,7 @@ FORMS once.
Return a list of the total elapsed time for execution, the number of
garbage collections that ran, and the time taken by garbage collection.
See also `benchmark-run-compiled'."
(declare (indent 1) (debug t))
(unless (natnump repetitions)
(setq forms (cons repetitions forms)
repetitions 1))
@ -69,8 +70,6 @@ See also `benchmark-run-compiled'."
`(benchmark-elapse ,@forms))
(- gcs-done ,gcs)
(- gc-elapsed ,gc)))))
(put 'benchmark-run 'edebug-form-spec t)
(put 'benchmark-run 'lisp-indent-function 2)
;;;###autoload
(defmacro benchmark-run-compiled (&optional repetitions &rest forms)
@ -78,6 +77,7 @@ See also `benchmark-run-compiled'."
This is like `benchmark-run', but what is timed is a funcall of the
byte code obtained by wrapping FORMS in a `lambda' and compiling the
result. The overhead of the `lambda's is accounted for."
(declare (indent 1) (debug t))
(unless (natnump repetitions)
(setq forms (cons repetitions forms)
repetitions 1))
@ -96,8 +96,6 @@ result. The overhead of the `lambda's is accounted for."
(funcall ,lambda-code))))
`(benchmark-elapse (funcall ,code)))
(- gcs-done ,gcs) (- gc-elapsed ,gc)))))
(put 'benchmark-run-compiled 'edebug-form-spec t)
(put 'benchmark-run-compiled 'lisp-indent-function 2)
;;;###autoload
(defun benchmark (repetitions form)

View file

@ -185,11 +185,10 @@ The return value is undefined.
((and (featurep 'cl)
(memq (car x) ;C.f. cl-do-proclaim.
'(special inline notinline optimize warn)))
(if (null (stringp docstring))
(push (list 'declare x) body)
(setcdr body (cons (list 'declare x) (cdr body))))
(push (list 'declare x)
(if (stringp docstring) (cdr body) body))
nil)
(t (message "Warning: Unknown defun property %S in %S"
(t (message "Warning: Unknown defun property `%S' in %S"
(car x) name)))))
decls))
(def (list 'defalias
@ -313,7 +312,7 @@ This uses `defvaralias' and `make-obsolete-variable' (which see).
See the Info node `(elisp)Variable Aliases' for more details.
If CURRENT-NAME is a defcustom (more generally, any variable
where OBSOLETE-NAME may be set, e.g. in a .emacs file, before the
where OBSOLETE-NAME may be set, e.g. in an init file, before the
alias is defined), then the define-obsolete-variable-alias
statement should be evaluated before the defcustom, if user
customizations are to be respected. The simplest way to achieve

View file

@ -1016,6 +1016,10 @@ Each function's symbol gets added to `byte-compile-noruntime-functions'."
((bufferp byte-compile-current-file)
(format "Buffer %s:"
(buffer-name byte-compile-current-file)))
;; We might be simply loading a file that
;; contains explicit calls to byte-compile functions.
((stringp load-file-name)
(format "%s:" (file-relative-name load-file-name dir)))
(t "")))
(pos (if (and byte-compile-current-file
(integerp byte-compile-read-position))

View file

@ -121,7 +121,7 @@ a future Emacs interpreter will be able to use it.")
;;; Generalized variables.
;; These macros are defined here so that they
;; can safely be used in .emacs files.
;; can safely be used in init files.
(defmacro cl-incf (place &optional x)
"Increment PLACE by X (1 by default).

View file

@ -249,8 +249,7 @@ Remove from SYMBOL's plist the property PROPNAME and its value.
;;;***
;;;### (autoloads (cl--compiler-macro-cXXr cl--compiler-macro-list*
;;;;;; cl--compiler-macro-adjoin cl-defsubst cl-compiler-macroexpand
;;;### (autoloads (cl--compiler-macro-adjoin cl-defsubst cl-compiler-macroexpand
;;;;;; cl-define-compiler-macro cl-assert cl-check-type cl-typep
;;;;;; cl-deftype cl-defstruct cl-callf2 cl-callf cl-letf* cl-letf
;;;;;; cl-rotatef cl-shiftf cl-remf cl-psetf cl-declare cl-the cl-locally
@ -260,9 +259,20 @@ Remove from SYMBOL's plist the property PROPNAME and its value.
;;;;;; cl-do cl-loop cl-return-from cl-return cl-block cl-etypecase
;;;;;; cl-typecase cl-ecase cl-case cl-load-time-value cl-eval-when
;;;;;; cl-destructuring-bind cl-function cl-defmacro cl-defun cl-gentemp
;;;;;; cl-gensym) "cl-macs" "cl-macs.el" "9676d5517e8b9246c09fe78984c68bef")
;;;;;; cl-gensym cl--compiler-macro-cXXr cl--compiler-macro-list*)
;;;;;; "cl-macs" "cl-macs.el" "6d0676869af66e5b5a671f95ee069461")
;;; Generated autoloads from cl-macs.el
(autoload 'cl--compiler-macro-list* "cl-macs" "\
\(fn FORM ARG &rest OTHERS)" nil nil)
(autoload 'cl--compiler-macro-cXXr "cl-macs" "\
\(fn FORM X)" nil nil)
(autoload 'cl-gensym "cl-macs" "\
Generate a new uninterned symbol.
The name is made by appending a number to PREFIX, default \"G\".
@ -659,6 +669,8 @@ value, that slot cannot be set via `setf'.
(put 'cl-defstruct 'doc-string-elt '2)
(put 'cl-defstruct 'lisp-indent-function '1)
(autoload 'cl-deftype "cl-macs" "\
Define NAME as a new data type.
The type name can then be used in `cl-typecase', `cl-check-type', etc.
@ -722,16 +734,6 @@ surrounded by (cl-block NAME ...).
\(fn FORM A LIST &rest KEYS)" nil nil)
(autoload 'cl--compiler-macro-list* "cl-macs" "\
\(fn FORM ARG &rest OTHERS)" nil nil)
(autoload 'cl--compiler-macro-cXXr "cl-macs" "\
\(fn FORM X)" nil nil)
;;;***
;;;### (autoloads (cl-tree-equal cl-nsublis cl-sublis cl-nsubst-if-not

View file

@ -58,6 +58,33 @@
;;; Initialization.
;; Place compiler macros at the beginning, otherwise uses of the corresponding
;; functions can lead to recursive-loads that prevent the calls from
;; being optimized.
;;;###autoload
(defun cl--compiler-macro-list* (_form arg &rest others)
(let* ((args (reverse (cons arg others)))
(form (car args)))
(while (setq args (cdr args))
(setq form `(cons ,(car args) ,form)))
form))
;;;###autoload
(defun cl--compiler-macro-cXXr (form x)
(let* ((head (car form))
(n (symbol-name (car form)))
(i (- (length n) 2)))
(if (not (string-match "c[ad]+r\\'" n))
(if (and (fboundp head) (symbolp (symbol-function head)))
(cl--compiler-macro-cXXr (cons (symbol-function head) (cdr form))
x)
(error "Compiler macro for cXXr applied to non-cXXr form"))
(while (> i (match-beginning 0))
(setq x (list (if (eq (aref n i) ?a) 'car 'cdr) x))
(setq i (1- i)))
x)))
;;; Some predicates for analyzing Lisp forms.
;; These are used by various
;; macro expanders to optimize the results in certain common cases.
@ -366,9 +393,14 @@ its argument list allows full Common Lisp conventions."
(mapcar (lambda (x)
(cond
((symbolp x)
(if (eq ?\& (aref (symbol-name x) 0))
(setq state x)
(make-symbol (upcase (symbol-name x)))))
(let ((first (aref (symbol-name x) 0)))
(if (eq ?\& first)
(setq state x)
;; Strip a leading underscore, since it only
;; means that this argument is unused.
(make-symbol (upcase (if (eq ?_ first)
(substring (symbol-name x) 1)
(symbol-name x)))))))
((not (consp x)) x)
((memq state '(nil &rest)) (cl--make-usage-args x))
(t ;(VAR INITFORM SVAR) or ((KEYWORD VAR) INITFORM SVAR).
@ -452,7 +484,13 @@ its argument list allows full Common Lisp conventions."
(let ((arg (pop args)))
(or (consp arg) (setq arg (list arg)))
(let* ((karg (if (consp (car arg)) (caar arg)
(intern (format ":%s" (car arg)))))
(let ((name (symbol-name (car arg))))
;; Strip a leading underscore, since it only
;; means that this argument is unused, but
;; shouldn't affect the key's name (bug#12367).
(if (eq ?_ (aref name 0))
(setq name (substring name 1)))
(intern (format ":%s" name)))))
(varg (if (consp (car arg)) (cl-cadar arg) (car arg)))
(def (if (cdr arg) (cadr arg)
(or (car cl--bind-defs) (cadr (assq varg cl--bind-defs)))))
@ -1425,8 +1463,15 @@ Valid clauses are:
cl--loop-accum-var))))
(defun cl--loop-build-ands (clauses)
"Return various representations of (and . CLAUSES).
CLAUSES is a list of Elisp expressions, where clauses of the form
\(progn E1 E2 E3 .. t) are the focus of particular optimizations.
The return value has shape (COND BODY COMBO)
such that COMBO is equivalent to (and . CLAUSES)."
(let ((ands nil)
(body nil))
;; Look through `clauses', trying to optimize (progn ,@A t) (progn ,@B) ,@C
;; into (progn ,@A ,@B) ,@C.
(while clauses
(if (and (eq (car-safe (car clauses)) 'progn)
(eq (car (last (car clauses))) t))
@ -1437,6 +1482,7 @@ Valid clauses are:
(cl-cdadr clauses)
(list (cadr clauses))))
(cddr clauses)))
;; A final (progn ,@A t) is moved outside of the `and'.
(setq body (cdr (butlast (pop clauses)))))
(push (pop clauses) ands)))
(setq ands (or (nreverse ands) (list t)))
@ -1905,8 +1951,6 @@ See Info node `(cl)Declarations' for details."
(cl-do-proclaim (pop specs) nil)))
nil)
;;; The standard modify macros.
;; `setf' is now part of core Elisp, defined in gv.el.
@ -1929,7 +1973,7 @@ before assigning any PLACEs to the corresponding values.
(or p (error "Odd number of arguments to cl-psetf"))
(pop p))
(if simple
`(progn (setf ,@args) nil)
`(progn (setq ,@args) nil)
(setq args (reverse args))
(let ((expr `(setf ,(cadr args) ,(car args))))
(while (setq args (cddr args))
@ -2119,7 +2163,7 @@ one keyword is supported, `:read-only'. If this has a non-nil
value, that slot cannot be set via `setf'.
\(fn NAME SLOTS...)"
(declare (doc-string 2)
(declare (doc-string 2) (indent 1)
(debug
(&define ;Makes top-level form not be wrapped.
[&or symbolp
@ -2597,14 +2641,6 @@ surrounded by (cl-block NAME ...).
`(if (cl-member ,a ,list ,@keys) ,list (cons ,a ,list))
form))
;;;###autoload
(defun cl--compiler-macro-list* (_form arg &rest others)
(let* ((args (reverse (cons arg others)))
(form (car args)))
(while (setq args (cdr args))
(setq form `(cons ,(car args) ,form)))
form))
(defun cl--compiler-macro-get (_form sym prop &optional def)
(if def
`(cl-getf (symbol-plist ,sym) ,prop ,def)
@ -2616,21 +2652,6 @@ surrounded by (cl-block NAME ...).
(cl--make-type-test temp (cl--const-expr-val type)))
form))
;;;###autoload
(defun cl--compiler-macro-cXXr (form x)
(let* ((head (car form))
(n (symbol-name (car form)))
(i (- (length n) 2)))
(if (not (string-match "c[ad]+r\\'" n))
(if (and (fboundp head) (symbolp (symbol-function head)))
(cl--compiler-macro-cXXr (cons (symbol-function head) (cdr form))
x)
(error "Compiler macro for cXXr applied to non-cXXr form"))
(while (> i (match-beginning 0))
(setq x (list (if (eq (aref n i) ?a) 'car 'cdr) x))
(setq i (1- i)))
x)))
(dolist (y '(cl-first cl-second cl-third cl-fourth
cl-fifth cl-sixth cl-seventh
cl-eighth cl-ninth cl-tenth

View file

@ -48,6 +48,39 @@ the middle is discarded, and just the beginning and end are displayed."
:group 'debugger
:version "21.1")
(defcustom debugger-bury-or-kill 'bury
"How to proceed with the debugger buffer when exiting `debug'.
The value used here affects the behavior of operations on any
window previously showing the debugger buffer.
`nil' means that if its window is not deleted when exiting the
debugger, invoking `switch-to-prev-buffer' will usually show
the debugger buffer again.
`append' means that if the window is not deleted, the debugger
buffer moves to the end of the window's previous buffers so
it's less likely that a future invocation of
`switch-to-prev-buffer' will switch to it. Also, it moves the
buffer to the end of the frame's buffer list.
`bury' means that if the window is not deleted, its buffer is
removed from the window's list of previous buffers. Also, it
moves the buffer to the end of the frame's buffer list. This
value provides the most reliable remedy to not have
`switch-to-prev-buffer' switch to the debugger buffer again
without killing the buffer.
`kill' means to kill the debugger buffer.
The value used here is passed to `quit-restore-window'."
:type '(choice
(const :tag "Keep alive" nil)
(const :tag "Append" 'append)
(const :tag "Bury" 'bury)
(const :tag "Kill" 'kill))
:group 'debugger
:version "24.2")
(defvar debug-function-list nil
"List of functions currently set for debug on entry.")
@ -60,6 +93,12 @@ the middle is discarded, and just the beginning and end are displayed."
(defvar debugger-old-buffer nil
"This is the buffer that was current when the debugger was entered.")
(defvar debugger-previous-window nil
"This is the window last showing the debugger buffer.")
(defvar debugger-previous-window-height nil
"The last recorded height of `debugger-previous-window'.")
(defvar debugger-previous-backtrace nil
"The contents of the previous backtrace (including text properties).
This is to optimize `debugger-make-xrefs'.")
@ -71,10 +110,6 @@ This is to optimize `debugger-make-xrefs'.")
(defvar debugger-outer-track-mouse)
(defvar debugger-outer-last-command)
(defvar debugger-outer-this-command)
;; unread-command-char is obsolete,
;; but we still save and restore it
;; in case some user program still tries to set it.
(defvar debugger-outer-unread-command-char)
(defvar debugger-outer-unread-command-events)
(defvar debugger-outer-unread-post-input-method-events)
(defvar debugger-outer-last-input-event)
@ -126,14 +161,12 @@ first will be printed into the backtrace buffer."
(unless noninteractive
(message "Entering debugger..."))
(let (debugger-value
(debug-on-error nil)
(debug-on-quit nil)
(debugger-previous-state
(if (get-buffer "*Backtrace*")
(with-current-buffer (get-buffer "*Backtrace*")
(list major-mode (buffer-string)))))
(debugger-buffer (get-buffer-create "*Backtrace*"))
(debugger-old-buffer (current-buffer))
(debugger-window nil)
(debugger-step-after-exit nil)
(debugger-will-be-back nil)
;; Don't keep reading from an executing kbd macro!
@ -148,8 +181,6 @@ first will be printed into the backtrace buffer."
(debugger-outer-track-mouse track-mouse)
(debugger-outer-last-command last-command)
(debugger-outer-this-command this-command)
(debugger-outer-unread-command-char
(with-no-warnings unread-command-char))
(debugger-outer-unread-command-events unread-command-events)
(debugger-outer-unread-post-input-method-events
unread-post-input-method-events)
@ -184,78 +215,74 @@ first will be printed into the backtrace buffer."
(cursor-in-echo-area nil))
(unwind-protect
(save-excursion
(save-window-excursion
(with-no-warnings
(setq unread-command-char -1))
(when (eq (car debugger-args) 'debug)
;; Skip the frames for backtrace-debug, byte-code,
;; and implement-debug-on-entry.
(backtrace-debug 4 t)
;; Place an extra debug-on-exit for macro's.
(when (eq 'lambda (car-safe (cadr (backtrace-frame 4))))
(backtrace-debug 5 t)))
(pop-to-buffer debugger-buffer)
(debugger-mode)
(debugger-setup-buffer debugger-args)
(when noninteractive
;; If the backtrace is long, save the beginning
;; and the end, but discard the middle.
(when (> (count-lines (point-min) (point-max))
debugger-batch-max-lines)
(goto-char (point-min))
(forward-line (/ 2 debugger-batch-max-lines))
(let ((middlestart (point)))
(goto-char (point-max))
(forward-line (- (/ 2 debugger-batch-max-lines)
debugger-batch-max-lines))
(delete-region middlestart (point)))
(insert "...\n"))
(when (eq (car debugger-args) 'debug)
;; Skip the frames for backtrace-debug, byte-code,
;; and implement-debug-on-entry.
(backtrace-debug 4 t)
;; Place an extra debug-on-exit for macro's.
(when (eq 'lambda (car-safe (cadr (backtrace-frame 4))))
(backtrace-debug 5 t)))
(pop-to-buffer
debugger-buffer
`((display-buffer-reuse-window
display-buffer-in-previous-window)
. (,(when debugger-previous-window
`(previous-window . ,debugger-previous-window)))))
(setq debugger-window (selected-window))
(if (eq debugger-previous-window debugger-window)
(when debugger-jumping-flag
;; Try to restore previous height of debugger
;; window.
(condition-case nil
(window-resize
debugger-window
(- debugger-previous-window-height
(window-total-size debugger-window)))
(error nil)))
(setq debugger-previous-window debugger-window))
(debugger-mode)
(debugger-setup-buffer debugger-args)
(when noninteractive
;; If the backtrace is long, save the beginning
;; and the end, but discard the middle.
(when (> (count-lines (point-min) (point-max))
debugger-batch-max-lines)
(goto-char (point-min))
(message "%s" (buffer-string))
(kill-emacs -1))
(forward-line (/ 2 debugger-batch-max-lines))
(let ((middlestart (point)))
(goto-char (point-max))
(forward-line (- (/ 2 debugger-batch-max-lines)
debugger-batch-max-lines))
(delete-region middlestart (point)))
(insert "...\n"))
(goto-char (point-min))
(message "%s" (buffer-string))
(kill-emacs -1))
(message "")
(let ((standard-output nil)
(buffer-read-only t))
(message "")
(let ((standard-output nil)
(buffer-read-only t))
(message "")
;; Make sure we unbind buffer-read-only in the right buffer.
(save-excursion
(recursive-edit)))))
;; Kill or at least neuter the backtrace buffer, so that users
;; don't try to execute debugger commands in an invalid context.
(if (get-buffer-window debugger-buffer 0)
;; Still visible despite the save-window-excursion? Maybe it
;; it's in a pop-up frame. It would be annoying to delete and
;; recreate it every time the debugger stops, so instead we'll
;; erase it (and maybe hide it) but keep it alive.
(with-current-buffer debugger-buffer
(with-selected-window (get-buffer-window debugger-buffer 0)
(when (and (window-dedicated-p (selected-window))
(not debugger-will-be-back))
;; If the window is not dedicated, burying the buffer
;; will mean that the frame created for it is left
;; around showing some random buffer, and next time we
;; pop to the debugger buffer we'll create yet
;; another frame.
;; If debugger-will-be-back is non-nil, the frame
;; would need to be de-iconified anyway immediately
;; after when we re-enter the debugger, so iconifying it
;; here would cause flashing.
;; Drew Adams is not happy with this: he wants to frame
;; to be left at the top-level, still working on how
;; best to do that.
(bury-buffer))))
(unless debugger-previous-state
(kill-buffer debugger-buffer)))
;; Restore the previous state of the debugger-buffer, in case we were
;; in a recursive invocation of the debugger.
(when (buffer-live-p debugger-buffer)
(with-current-buffer debugger-buffer
(let ((inhibit-read-only t))
(erase-buffer)
(if (null debugger-previous-state)
(fundamental-mode)
(insert (nth 1 debugger-previous-state))
(funcall (nth 0 debugger-previous-state))))))
;; Make sure we unbind buffer-read-only in the right buffer.
(save-excursion
(recursive-edit))))
(when (and (window-live-p debugger-window)
(eq (window-buffer debugger-window) debugger-buffer))
;; Record height of debugger window.
(setq debugger-previous-window-height
(window-total-size debugger-window))
;; Unshow debugger-buffer.
(quit-restore-window debugger-window debugger-bury-or-kill))
;; Restore previous state of debugger-buffer in case we were
;; in a recursive invocation of the debugger, otherwise just
;; erase the buffer and put it into fundamental mode.
(when (buffer-live-p debugger-buffer)
(with-current-buffer debugger-buffer
(let ((inhibit-read-only t))
(erase-buffer)
(if (null debugger-previous-state)
(fundamental-mode)
(insert (nth 1 debugger-previous-state))
(funcall (nth 0 debugger-previous-state))))))
(with-timeout-unsuspend debugger-with-timeout-suspend)
(set-match-data debugger-outer-match-data)))
;; Put into effect the modified values of these variables
@ -267,8 +294,6 @@ first will be printed into the backtrace buffer."
(setq track-mouse debugger-outer-track-mouse)
(setq last-command debugger-outer-last-command)
(setq this-command debugger-outer-this-command)
(with-no-warnings
(setq unread-command-char debugger-outer-unread-command-char))
(setq unread-command-events debugger-outer-unread-command-events)
(setq unread-post-input-method-events
debugger-outer-unread-post-input-method-events)
@ -570,16 +595,7 @@ Applies to the frame whose line point is on in the backtrace."
(cursor-in-echo-area debugger-outer-cursor-in-echo-area))
(set-match-data debugger-outer-match-data)
(prog1
(let ((save-ucc (with-no-warnings unread-command-char)))
(unwind-protect
(progn
(with-no-warnings
(setq unread-command-char debugger-outer-unread-command-char))
(prog1 (progn ,@body)
(with-no-warnings
(setq debugger-outer-unread-command-char unread-command-char))))
(with-no-warnings
(setq unread-command-char save-ucc))))
(progn ,@body)
(setq debugger-outer-match-data (match-data))
(setq debugger-outer-load-read-function load-read-function)
(setq debugger-outer-overriding-terminal-local-map

View file

@ -148,7 +148,7 @@ unselectable text. A string consisting solely of hyphens is displayed
as a solid horizontal line.
A menu item can be a list with the same format as MENU. This is a submenu."
(declare (indent defun))
(declare (indent defun) (debug (symbolp body)))
`(progn
,(if symbol `(defvar ,symbol nil ,doc))
(easy-menu-do-define (quote ,symbol) ,maps ,doc ,menu)))

File diff suppressed because it is too large Load diff

View file

@ -431,6 +431,61 @@ if that value is non-nil."
(add-hook 'completion-at-point-functions
'lisp-completion-at-point nil 'local))
;;; Emacs Lisp Byte-Code mode
(eval-and-compile
(defconst emacs-list-byte-code-comment-re
(concat "\\(#\\)@\\([0-9]+\\) "
;; Make sure it's a docstring and not a lazy-loaded byte-code.
"\\(?:[^(]\\|([^\"]\\)")))
(defun emacs-lisp-byte-code-comment (end &optional _point)
"Try to syntactically mark the #@NNN ....^_ docstrings in byte-code files."
(let ((ppss (syntax-ppss)))
(when (and (nth 4 ppss)
(eq (char-after (nth 8 ppss)) ?#))
(let* ((n (save-excursion
(goto-char (nth 8 ppss))
(when (looking-at emacs-list-byte-code-comment-re)
(string-to-number (match-string 2)))))
;; `maxdiff' tries to make sure the loop below terminates.
(maxdiff n))
(when n
(let* ((bchar (match-end 2))
(b (position-bytes bchar)))
(goto-char (+ b n))
(while (let ((diff (- (position-bytes (point)) b n)))
(unless (zerop diff)
(when (> diff maxdiff) (setq diff maxdiff))
(forward-char (- diff))
(setq maxdiff (if (> diff 0) diff
(max (1- maxdiff) 1)))
t))))
(if (<= (point) end)
(put-text-property (1- (point)) (point)
'syntax-table
(string-to-syntax "> b"))
(goto-char end)))))))
(defun emacs-lisp-byte-code-syntax-propertize (start end)
(emacs-lisp-byte-code-comment end (point))
(funcall
(syntax-propertize-rules
(emacs-list-byte-code-comment-re
(1 (prog1 "< b" (emacs-lisp-byte-code-comment end (point))))))
start end))
(add-to-list 'auto-mode-alist '("\\.elc\\'" . emacs-lisp-byte-code-mode))
(define-derived-mode emacs-lisp-byte-code-mode emacs-lisp-mode
"Elisp-Byte-Code"
"Major mode for *.elc files."
;; TODO: Add way to disassemble byte-code under point.
(setq-local open-paren-in-column-0-is-defun-start nil)
(setq-local syntax-propertize-function
#'emacs-lisp-byte-code-syntax-propertize))
;;; Generic Lisp mode.
(defvar lisp-mode-map
(let ((map (make-sparse-keymap))
(menu-map (make-sparse-keymap "Lisp")))
@ -730,10 +785,12 @@ POS specifies the starting position where EXP was found and defaults to point."
(let ((vars ()))
(goto-char (point-min))
(while (re-search-forward
"^(def\\(?:var\\|const\\|custom\\)[ \t\n]+\\([^; '()\n\t]+\\)"
"(def\\(?:var\\|const\\|custom\\)[ \t\n]+\\([^; '()\n\t]+\\)"
pos t)
(let ((var (intern (match-string 1))))
(unless (special-variable-p var)
(and (not (special-variable-p var))
(save-excursion
(zerop (car (syntax-ppss (match-beginning 0)))))
(push var vars))))
`(progn ,@(mapcar (lambda (v) `(defvar ,v)) vars) ,exp)))))
@ -820,7 +877,6 @@ if it already has a value.\)
With argument, insert value in current buffer after the defun.
Return the result of evaluation."
(interactive "P")
;; FIXME: the print-length/level bindings should only be applied while
;; printing, not while evaluating.
(let ((debug-on-error eval-expression-debug-on-error)
@ -925,6 +981,7 @@ rigidly along with this one."
(if (or (null indent) (looking-at "\\s<\\s<\\s<"))
;; Don't alter indentation of a ;;; comment line
;; or a line that starts in a string.
;; FIXME: inconsistency: comment-indent moves ;;; to column 0.
(goto-char (- (point-max) pos))
(if (and (looking-at "\\s<") (not (looking-at "\\s<\\s<")))
;; Single-semicolon comment lines should be indented
@ -939,18 +996,7 @@ rigidly along with this one."
;; If initial point was within line's indentation,
;; position after the indentation. Else stay at same point in text.
(if (> (- (point-max) pos) (point))
(goto-char (- (point-max) pos)))
;; If desired, shift remaining lines of expression the same amount.
(and whole-exp (not (zerop shift-amt))
(save-excursion
(goto-char beg)
(forward-sexp 1)
(setq end (point))
(goto-char beg)
(forward-line 1)
(setq beg (point))
(> end beg))
(indent-code-rigidly beg end shift-amt)))))
(goto-char (- (point-max) pos))))))
(defvar calculate-lisp-indent-last-sexp)
@ -1230,7 +1276,6 @@ Lisp function does not specify a special indentation."
(put 'prog2 'lisp-indent-function 2)
(put 'save-excursion 'lisp-indent-function 0)
(put 'save-restriction 'lisp-indent-function 0)
(put 'save-match-data 'lisp-indent-function 0)
(put 'save-current-buffer 'lisp-indent-function 0)
(put 'let 'lisp-indent-function 1)
(put 'let* 'lisp-indent-function 1)

View file

@ -100,6 +100,17 @@ each clause."
(error (message "Compiler-macro error for %S: %S" (car form) err)
form)))
(defun macroexp--eval-if-compile (&rest _forms)
"Pseudo function used internally by macroexp to delay warnings.
The purpose is to delay warnings to bytecomp.el, so they can use things
like `byte-compile-log-warning' to get better file-and-line-number data
and also to avoid outputting the warning during normal execution."
nil)
(put 'macroexp--eval-if-compile 'byte-compile
(lambda (form)
(mapc (lambda (x) (funcall (eval x))) (cdr form))
(byte-compile-constant nil)))
(defun macroexp--expand-all (form)
"Expand all macros in FORM.
This is an internal version of `macroexpand-all'.
@ -112,14 +123,17 @@ Assumes the caller has bound `macroexpand-all-environment'."
(macroexpand (macroexp--all-forms form 1)
macroexpand-all-environment)
;; Normal form; get its expansion, and then expand arguments.
(let ((new-form (macroexpand form macroexpand-all-environment)))
(when (and (not (eq form new-form)) ;It was a macro call.
(car-safe form)
(symbolp (car form))
(get (car form) 'byte-obsolete-info)
(fboundp 'byte-compile-warn-obsolete))
(byte-compile-warn-obsolete (car form)))
(setq form new-form))
(let ((new-form
(macroexpand form macroexpand-all-environment)))
(setq form
(if (and (not (eq form new-form)) ;It was a macro call.
(car-safe form)
(symbolp (car form))
(get (car form) 'byte-obsolete-info))
`(progn (macroexp--eval-if-compile
(lambda () (byte-compile-warn-obsolete ',(car form))))
,new-form)
new-form)))
(pcase form
(`(cond . ,clauses)
(macroexp--cons 'cond (macroexp--all-clauses clauses) form))
@ -323,6 +337,86 @@ symbol itself."
"Return non-nil if EXP can be copied without extra cost."
(or (symbolp exp) (macroexp-const-p exp)))
;;; Load-time macro-expansion.
;; Because macro-expansion used to be more lazy, eager macro-expansion
;; tends to bump into previously harmless/unnoticeable cyclic-dependencies.
;; So, we have to delay macro-expansion like we used to when we detect
;; such a cycle, and we also want to help coders resolve those cycles (since
;; they can be non-obvious) by providing a usefully trimmed backtrace
;; (hopefully) highlighting the problem.
(defun macroexp--backtrace ()
"Return the Elisp backtrace, more recent frames first."
(let ((bt ())
(i 0))
(while
(let ((frame (backtrace-frame i)))
(when frame
(push frame bt)
(setq i (1+ i)))))
(nreverse bt)))
(defun macroexp--trim-backtrace-frame (frame)
(pcase frame
(`(,_ macroexpand (,head . ,_) . ,_) `(macroexpand (,head )))
(`(,_ internal-macroexpand-for-load (,head ,second . ,_) . ,_)
(if (or (symbolp second)
(and (eq 'quote (car-safe second))
(symbolp (cadr second))))
`(macroexpand-all (,head ,second ))
'(macroexpand-all )))
(`(,_ load-with-code-conversion ,name . ,_)
`(load ,(file-name-nondirectory name)))))
(defvar macroexp--pending-eager-loads nil
"Stack of files currently undergoing eager macro-expansion.")
(defun internal-macroexpand-for-load (form)
;; Called from the eager-macroexpansion in readevalloop.
(cond
;; Don't repeat the same warning for every top-level element.
((eq 'skip (car macroexp--pending-eager-loads)) form)
;; If we detect a cycle, skip macro-expansion for now, and output a warning
;; with a trimmed backtrace.
((and load-file-name (member load-file-name macroexp--pending-eager-loads))
(let* ((bt (delq nil
(mapcar #'macroexp--trim-backtrace-frame
(macroexp--backtrace))))
(elem `(load ,(file-name-nondirectory load-file-name)))
(tail (member elem (cdr (member elem bt)))))
(if tail (setcdr tail (list ')))
(if (eq (car-safe (car bt)) 'macroexpand-all) (setq bt (cdr bt)))
(message "Warning: Eager macro-expansion skipped due to cycle:\n %s"
(mapconcat #'prin1-to-string (nreverse bt) " => "))
(push 'skip macroexp--pending-eager-loads)
form))
(t
(condition-case err
(let ((macroexp--pending-eager-loads
(cons load-file-name macroexp--pending-eager-loads)))
(macroexpand-all form))
(error
;; Hopefully this shouldn't happen thanks to the cycle detection,
;; but in case it does happen, let's catch the error and give the
;; code a chance to macro-expand later.
(message "Eager macro-expansion failure: %S" err)
form)))))
;; ¡¡¡ Big Ugly Hack !!!
;; src/bootstrap-emacs is mostly used to compile .el files, so it needs
;; macroexp, bytecomp, cconv, and byte-opt to be fast. Generally this is done
;; by compiling those files first, but this only makes a difference if those
;; files are not preloaded. But macroexp.el is preloaded so we reload it if
;; the current version is interpreted and there's a compiled version available.
(eval-when-compile
(add-hook 'emacs-startup-hook
(lambda ()
(and (not (byte-code-function-p
(symbol-function 'macroexpand-all)))
(locate-library "macroexp.elc")
(load "macroexp.elc")))))
(provide 'macroexp)
;;; macroexp.el ends here

View file

@ -123,16 +123,6 @@ Returns the number of actions taken."
map
(let ((map (make-sparse-keymap)))
(set-keymap-parent map query-replace-map)
(define-key map [?\C-\M-v] 'scroll-other-window)
(define-key map [M-next] 'scroll-other-window)
(define-key map [?\C-\M-\S-v] 'scroll-other-window-down)
(define-key map [M-prior] 'scroll-other-window-down)
;; The above are rather inconvenient, so maybe we should
;; provide the non-other keys for the other-scroll as well.
;; (define-key map [?\C-v] 'scroll-other-window)
;; (define-key map [next] 'scroll-other-window)
;; (define-key map [?\M-v] 'scroll-other-window-down)
;; (define-key map [prior] 'scroll-other-window-down)
(dolist (elt action-alist)
(define-key map (vector (car elt)) (vector (nth 1 elt))))
map)))

View file

@ -60,6 +60,8 @@
;; is in a loop, the repeated macro-expansion becomes terribly costly, so we
;; memoize previous macro expansions to try and avoid recomputing them
;; over and over again.
;; FIXME: Now that macroexpansion is also performed when loading an interpreted
;; file, this is not a real problem any more.
(defconst pcase--memoize (make-hash-table :weakness 'key :test 'eq))
;; (defconst pcase--memoize-1 (make-hash-table :test 'eq))
;; (defconst pcase--memoize-2 (make-hash-table :weakness 'key :test 'equal))

Some files were not shown because too many files have changed in this diff Show more