Merge from trunk.
This commit is contained in:
commit
ce1d7b61f1
314 changed files with 10923 additions and 10169 deletions
|
@ -7,7 +7,8 @@
|
|||
;; See admin/notes/bugtracker.
|
||||
(log-edit-mode . ((log-edit-rewrite-fixes
|
||||
"[ \n](bug#\\([0-9]+\\))" . "debbugs:\\1")
|
||||
(log-edit-font-lock-gnu-style . t)))
|
||||
(log-edit-font-lock-gnu-style . t)
|
||||
(log-edit-setup-add-author . t)))
|
||||
(change-log-mode . ((add-log-time-zone-rule . t)
|
||||
(fill-column . 74)
|
||||
(bug-reference-url-format . "http://debbugs.gnu.org/%s")
|
||||
|
|
87
ChangeLog
87
ChangeLog
|
@ -1,3 +1,90 @@
|
|||
2013-12-01 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* .dir-locals.el (log-edit-move): Add the "Author: " header.
|
||||
|
||||
2013-11-30 Dani Moncayo <dmoncayo@gmail.com>
|
||||
|
||||
* build-aux/msys-to-w32 (w32pathlist): Do not translate paths
|
||||
starting with %emacs_dir%.
|
||||
|
||||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
Stop keeping (most) generated cedet grammar files in the repository.
|
||||
* configure.ac (SUBDIR_MAKEFILES, AC_CONFIG_FILES):
|
||||
Add admin/grammars Makefile.
|
||||
* Makefile.in (distclean, bootstrap-clean, maintainer-clean):
|
||||
Also clean admin/grammars, if present.
|
||||
|
||||
2013-11-29 Dani Moncayo <dmoncayo@gmail.com>
|
||||
|
||||
* Makefile.in (epaths-force-w32): Fix 2013-11-20 typo.
|
||||
|
||||
2013-11-29 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* configure.ac (HAVE_MENUS): Remove.
|
||||
|
||||
2013-11-28 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* configure.ac (PATH_SEP): Replace with pre-existing SEPCHAR.
|
||||
|
||||
2013-11-28 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* GNUmakefile (Makefile): Don't use $(CFG).
|
||||
(CFG): Don't compute.
|
||||
|
||||
* configure.ac (PATH_SEP): Set and AC_SUBST.
|
||||
|
||||
2013-11-27 Paul Eggert <eggert@cs.ucla.edu>
|
||||
|
||||
Merge from gnulib, incorporating:
|
||||
2013-11-13 getgroups: work around _DARWIN_C_SOURCE problem
|
||||
* lib/getgroups.c: Update from gnulib.
|
||||
|
||||
2013-11-27 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
Move ja-dic, quail, leim-list.el from leim to lisp/leim.
|
||||
* Makefile.in (abs_builddir, leimdir): Remove.
|
||||
(buildlisppath, SUBDIR, COPYDIR, COPYDESTS): No more leim directory.
|
||||
(epaths-force-w32): No longer set BLD.
|
||||
(leim): Remove.
|
||||
(install-arch-indep): No longer run or install leim.
|
||||
(mostlyclean, clean): No longer run leim rule.
|
||||
(bootstrap-clean): Change leim target.
|
||||
(maintainer-clean): Add leim.
|
||||
(check-declare): Remove leim.
|
||||
* README: Update for leim changes.
|
||||
* configure.ac (leimdir): Remove.
|
||||
(standardlisppath): No more leimdir.
|
||||
|
||||
* make-dist: Update for files from leim/ now being in lisp/leim/.
|
||||
|
||||
2013-11-26 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
Preload leim-list.el.
|
||||
* Makefile.in (abs_builddir): New, set by configure.
|
||||
(buildlisppath): Add leim/.
|
||||
(epaths-force-w32): Set BLD.
|
||||
|
||||
2013-11-21 Paul Eggert <eggert@cs.ucla.edu>
|
||||
|
||||
Fix some dependency problems that cause unnecessary recompiles.
|
||||
* configure.ac (OLDXMENU_TARGET, OLDXMENU, OLDXMENU_DEPS):
|
||||
Remove.
|
||||
(LIBXMENU): Now is always either empty or a file name,
|
||||
so that it can be used as a dependency.
|
||||
|
||||
2013-11-20 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* make-dist: Distribute build-aux/msys-to-w32.
|
||||
|
||||
2013-11-20 Dani Moncayo <dmoncayo@gmail.com>
|
||||
|
||||
* build-aux/msys-to-w32: New file.
|
||||
* Makefile.in (msys_to_w32, msys_lisppath_to_w32): Remove.
|
||||
(msys_w32prefix_subst): Rename from msys_prefix_subst.
|
||||
Operate on w32prefixpattern.
|
||||
(epaths-force-w32): Use build-aux/msys-to-w32.
|
||||
|
||||
2013-11-17 Paul Eggert <eggert@cs.ucla.edu>
|
||||
|
||||
* configure.ac (DEBUGGER_SEES_C_MACROS): Remove.
|
||||
|
|
|
@ -32,12 +32,6 @@
|
|||
# run "configure" by hand. But run autogen.sh first, if the source
|
||||
# was checked out directly from the repository.
|
||||
|
||||
ifneq ($(MSYSTEM),)
|
||||
CFG = CONFIG_SITE=$(CURDIR)/nt/mingw-cfg.site
|
||||
else
|
||||
CFG =
|
||||
endif
|
||||
|
||||
# If a Makefile already exists, just use it.
|
||||
|
||||
ifeq ($(wildcard Makefile),Makefile)
|
||||
|
@ -75,7 +69,7 @@ configure:
|
|||
Makefile: configure
|
||||
@echo >&2 'There seems to be no Makefile in this directory.'
|
||||
@echo >&2 'Running ./configure ...'
|
||||
$(CFG) ./configure
|
||||
./configure
|
||||
@echo >&2 'Makefile built.'
|
||||
|
||||
endif
|
||||
|
|
111
Makefile.in
111
Makefile.in
|
@ -48,6 +48,8 @@
|
|||
#
|
||||
# make extraclean
|
||||
# Still more severe - delete backup and autosave files, too.
|
||||
# Also generated files that do not normally change and can be slow
|
||||
# to rebuild (eg leim/ja-dic).
|
||||
#
|
||||
# make bootstrap
|
||||
# Removes all the compiled files to force a new bootstrap from a
|
||||
|
@ -190,15 +192,13 @@ iconsrcdir=$(srcdir)/etc/images/icons
|
|||
# These variables hold the values Emacs will actually use. They are
|
||||
# based on the values of the standard Make variables above.
|
||||
|
||||
# Where to install the lisp, leim files distributed with
|
||||
# Emacs. This includes the Emacs version, so that the
|
||||
# lisp files for different versions of Emacs will install
|
||||
# themselves in separate directories.
|
||||
# Where to install the lisp files distributed with Emacs.
|
||||
# This includes the Emacs version, so that the lisp files for different
|
||||
# versions of Emacs will install themselves in separate directories.
|
||||
lispdir=@lispdir@
|
||||
leimdir=@leimdir@
|
||||
|
||||
# Directories Emacs should search for standard lisp files.
|
||||
# The default is ${lispdir}:${leimdir}.
|
||||
# The default is ${lispdir}.
|
||||
standardlisppath=@standardlisppath@
|
||||
|
||||
# Directories Emacs should search for lisp files specific to this
|
||||
|
@ -213,12 +213,13 @@ locallisppath=@locallisppath@
|
|||
# The default is ${locallisppath}:${standardlisppath}.
|
||||
lisppath=@lisppath@
|
||||
|
||||
# Where Emacs will search for its lisp files while
|
||||
# building. This is only used during the process of
|
||||
# compiling Emacs, to help Emacs find its lisp files
|
||||
# before they've been installed in their final location.
|
||||
# Where Emacs will search for its lisp files while building.
|
||||
# This is only used during the process of compiling Emacs,
|
||||
# to help Emacs find its lisp files before they've been installed
|
||||
# in their final location.
|
||||
# This should be a colon-separated list of directories.
|
||||
# Normally it points to the lisp/ directory in the sources.
|
||||
# NB lread.c relies on lisp/ being first here.
|
||||
buildlisppath=${abs_srcdir}/lisp
|
||||
|
||||
# Where to install the other architecture-independent
|
||||
|
@ -274,7 +275,7 @@ EMACS = ${EMACS_NAME}${EXEEXT}
|
|||
EMACSFULL = `echo emacs-${version} | sed '$(TRANSFORM)'`${EXEEXT}
|
||||
|
||||
# Subdirectories to make recursively.
|
||||
SUBDIR = $(NTDIR) lib lib-src src lisp leim
|
||||
SUBDIR = $(NTDIR) lib lib-src src lisp
|
||||
|
||||
# The subdir makefiles created by config.status.
|
||||
SUBDIR_MAKEFILES_IN = @SUBDIR_MAKEFILES_IN@
|
||||
|
@ -283,10 +284,9 @@ SUBDIR_MAKEFILES = `echo $(SUBDIR_MAKEFILES_IN:.in=) | sed 's|$(srcdir)/||g'`
|
|||
# Subdirectories to install, and where they'll go. lib-src's and nt's
|
||||
# makefiles know how to install them, so we don't do that here.
|
||||
# Directories that cannot simply be copied, eg info, are treated
|
||||
# separately. quail appears twice because in out-of-tree builds, it
|
||||
# exists twice.
|
||||
COPYDIR = ${srcdir}/etc ${srcdir}/lisp ${srcdir}/leim/ja-dic ${srcdir}/leim/quail leim/quail
|
||||
COPYDESTS = "$(DESTDIR)${etcdir}" "$(DESTDIR)${lispdir}" "$(DESTDIR)${leimdir}/ja-dic" "$(DESTDIR)${leimdir}/quail" "$(DESTDIR)${leimdir}/quail"
|
||||
# separately.
|
||||
COPYDIR = ${srcdir}/etc ${srcdir}/lisp
|
||||
COPYDESTS = "$(DESTDIR)${etcdir}" "$(DESTDIR)${lispdir}"
|
||||
|
||||
all: ${SUBDIR}
|
||||
|
||||
|
@ -317,22 +317,9 @@ epaths-force: FRC
|
|||
-e 's;\(#.*PATH_DOC\).*$$;\1 "${etcdocdir}";') && \
|
||||
${srcdir}/build-aux/move-if-change epaths.h.$$$$ src/epaths.h
|
||||
|
||||
# Convert MSYS-style /x/foo or Windows-style x:\foo file names
|
||||
# into x:/foo that Windows can grok.
|
||||
msys_to_w32=sed -e 's,\\\\,/,g' -e 's,^/\([A-Za-z]\)/,\1:/,'
|
||||
|
||||
# Transform directory search path and its components. Original can
|
||||
# be MSYS or Windows style. Set path separator to ";", directory
|
||||
# separator to "/" and transform MSYS-style "/c/" to "c:/".
|
||||
# Remove empty path components and escape semicolons.
|
||||
msys_lisppath_to_w32=sed -e 's,\\\\,/,g' \
|
||||
-e 's,\(^\|[:;]\)\([A-Za-z]\):/,\1/\2/,g' \
|
||||
-e 's/:/;/g' -e 's,\(^\|;\)/\([A-Za-z]\)/,\1\2:/,g' \
|
||||
-e 's/;\+/;/g' -e 's/^;//' -e 's/;$$//' -e 's/;/\\\\;/g'
|
||||
|
||||
# Replace "${prefix}" with '%emacs_dir%' (which expands to install
|
||||
# Replace "${w32prefix}" with '%emacs_dir%' (which expands to install
|
||||
# directory at runtime).
|
||||
msys_prefix_subst=sed -e 's!\(^\|;\)'"$${prefixpattern}"'\([;/]\|$$\)!\1%emacs_dir%\2!g'
|
||||
msys_w32prefix_subst=sed -e 's!\(^\|;\)'"$${w32prefixpattern}"'\([;/]\|$$\)!\1%emacs_dir%\2!g'
|
||||
|
||||
# Quote Sed special characters (except backslash and newline) with
|
||||
# a double backslash.
|
||||
|
@ -340,22 +327,21 @@ msys_sed_sh_escape=sed -e 's/[];$$*.^[]/\\\\&/g'
|
|||
|
||||
# The w32 build needs a slightly different editing, and it uses
|
||||
# nt/epaths.nt as the template.
|
||||
#
|
||||
# Use the value of ${locallisppath} supplied by `configure',
|
||||
# to support the --enable-locallisppath argument.
|
||||
#
|
||||
# When building with MinGW inside the MSYS tree, 'pwd' produces directories
|
||||
# relative to the root of the MSYS tree, e.g. '/home/user/foo' instead of
|
||||
# '/d/MSYS/home/user/foo'. If such a value of srcdir is written to
|
||||
# src/epaths.h, that causes temacs to fail, because, being a MinGW
|
||||
# program that knows nothing of MSYS root substitution, it cannot find
|
||||
# the data directory. "pwd -W" produces Windows-style 'd:/foo/bar'
|
||||
# absolute directory names, so we use it here to countermand that lossage.
|
||||
# In this case, the paths written to 'src/epaths.h' must be in native
|
||||
# MS-Windows format (e.g. 'c:/foo/bar'), because temacs is a MinGW
|
||||
# program that doesn't support MSYS-style paths (e.g. '/c/foo/bar' or
|
||||
# '/foo/bar').
|
||||
epaths-force-w32: FRC
|
||||
@(w32srcdir=`cd "${srcdir}" && pwd -W` ; \
|
||||
prefixpattern=`echo '${prefix}' | ${msys_to_w32} | ${msys_sed_sh_escape}` ; \
|
||||
locallisppath=`echo '${locallisppath}' | ${msys_lisppath_to_w32} | ${msys_prefix_subst}` ; \
|
||||
@(w32srcdir=`${srcdir}/build-aux/msys-to-w32 "${srcdir}"`; \
|
||||
w32prefix=`${srcdir}/build-aux/msys-to-w32 "${prefix}" N`; \
|
||||
w32prefixpattern=`echo "$${w32prefix}" | ${msys_sed_sh_escape}` ; \
|
||||
w32locallisppath=`${srcdir}/build-aux/msys-to-w32 "${locallisppath}" N ":" "\\;" | ${msys_w32prefix_subst}` ; \
|
||||
sed < ${srcdir}/nt/epaths.nt > epaths.h.$$$$ \
|
||||
-e 's;\(#.*PATH_SITELOADSEARCH\).*$$;\1 "'"$${locallisppath}"'";' \
|
||||
-e 's;\(#.*PATH_SITELOADSEARCH\).*$$;\1 "'"$${w32locallisppath}"'";' \
|
||||
-e '/^.*#/s/@VER@/${version}/g' \
|
||||
-e '/^.*#/s/@CFG@/${configuration}/g' \
|
||||
-e "/^.*#/s|@SRC@|$${w32srcdir}|g") && \
|
||||
|
@ -369,12 +355,11 @@ lib-src src: $(NTDIR) lib
|
|||
|
||||
src: lib-src
|
||||
|
||||
# We need to build `emacs' in `src' to compile the *.elc files in `lisp'
|
||||
# and `leim'.
|
||||
lisp leim: src
|
||||
# We need to build `emacs' in `src' to compile the *.elc files in `lisp'.
|
||||
lisp: src
|
||||
|
||||
# These targets should be "${SUBDIR} without `src'".
|
||||
lib lib-src lisp leim nt: Makefile FRC
|
||||
lib lib-src lisp nt: Makefile FRC
|
||||
cd $@ && $(MAKE) all $(MFLAGS) \
|
||||
CC='${CC}' CFLAGS='${CFLAGS}' CPPFLAGS='${CPPFLAGS}' \
|
||||
LDFLAGS='${LDFLAGS}' MAKE='${MAKE}'
|
||||
|
@ -561,9 +546,12 @@ set_installuser=for installuser in $${LOGNAME} $${USERNAME} $${USER} \
|
|||
## Note that the Makefiles in the etc directory are potentially useful
|
||||
## in an installed Emacs, so should not be excluded.
|
||||
|
||||
## We used to create locallisppath, but if it points to non-standard
|
||||
## locations, is not really Emacs's job to create these directories,
|
||||
## so it is no longer done.
|
||||
## We always create the _default_ locallisppath directories, and
|
||||
## ensure that they contain a subdirs.el file (via write_subdir).
|
||||
## This is true even if locallisppath has a non-default value.
|
||||
## In case of non-default value, we used to create the specified directories,
|
||||
## but not add subdirs.el to them. This was a strange halfway house.
|
||||
## Nowadays we do not create non-default directories.
|
||||
|
||||
## Note that we use tar instead of plain old cp -R/-r because the latter
|
||||
## is apparently not portable (even in 2012!).
|
||||
|
@ -572,7 +560,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: lisp leim install-info install-man ${INSTALL_ARCH_INDEP_EXTRA}
|
||||
install-arch-indep: lisp install-info install-man ${INSTALL_ARCH_INDEP_EXTRA}
|
||||
-set ${COPYDESTS} ; \
|
||||
unset CDPATH; \
|
||||
$(set_installuser); \
|
||||
|
@ -584,13 +572,8 @@ install-arch-indep: lisp leim install-info install-man ${INSTALL_ARCH_INDEP_EXTR
|
|||
[ "$$exp_dest" = "`cd $${dir} && /bin/pwd`" ] && continue ; \
|
||||
else true; \
|
||||
fi; \
|
||||
if [ "$${dir}" = "leim/quail" ]; then \
|
||||
[ "`cd $${dir} && /bin/pwd`" = "`cd ${srcdir}/leim/quail && /bin/pwd`" ] && \
|
||||
continue ; \
|
||||
else \
|
||||
rm -rf "$${dest}" ; \
|
||||
umask 022; ${MKDIR_P} "$${dest}" ; \
|
||||
fi ; \
|
||||
rm -rf "$${dest}" ; \
|
||||
umask 022; ${MKDIR_P} "$${dest}" ; \
|
||||
echo "Copying $${dir} to $${dest}..." ; \
|
||||
(cd $${dir}; tar -chf - . ) \
|
||||
| (cd "$${dest}"; umask 022; \
|
||||
|
@ -617,8 +600,6 @@ install-arch-indep: lisp leim install-info install-man ${INSTALL_ARCH_INDEP_EXTR
|
|||
done ); \
|
||||
find "$${dest}" -exec chown $${installuser} {} ';' ;\
|
||||
done
|
||||
-rm -f "$(DESTDIR)${leimdir}/leim-list.el"
|
||||
${INSTALL_DATA} leim/leim-list.el "$(DESTDIR)${leimdir}/leim-list.el"
|
||||
-rm -f "$(DESTDIR)${lispdir}/subdirs.el"
|
||||
umask 022; $(srcdir)/build-aux/update-subdirs "$(DESTDIR)${lispdir}"
|
||||
subdir="$(DESTDIR)${datadir}/emacs/${version}/site-lisp" ; \
|
||||
|
@ -629,7 +610,7 @@ install-arch-indep: lisp leim install-info install-man ${INSTALL_ARCH_INDEP_EXTR
|
|||
( echo "Compressing *.el ..." ; \
|
||||
unset CDPATH; \
|
||||
thisdir=`/bin/pwd`; \
|
||||
for dir in "$(DESTDIR)${lispdir}" "$(DESTDIR)${leimdir}"; do \
|
||||
for dir in "$(DESTDIR)${lispdir}"; do \
|
||||
cd "$${thisdir}" ; \
|
||||
cd "$${dir}" || exit 1 ; \
|
||||
for f in `find . -name "*.elc" -print`; do \
|
||||
|
@ -826,7 +807,6 @@ mostlyclean: FRC
|
|||
-cd doc/misc && $(MAKE) $(MFLAGS) mostlyclean
|
||||
-cd doc/lispref && $(MAKE) $(MFLAGS) mostlyclean
|
||||
-cd doc/lispintro && $(MAKE) $(MFLAGS) mostlyclean
|
||||
cd leim && $(MAKE) $(MFLAGS) mostlyclean
|
||||
|
||||
### `clean'
|
||||
### Delete all files from the current directory that are normally
|
||||
|
@ -848,7 +828,6 @@ clean: FRC
|
|||
-cd doc/misc && $(MAKE) $(MFLAGS) clean
|
||||
-cd doc/lispref && $(MAKE) $(MFLAGS) clean
|
||||
-cd doc/lispintro && $(MAKE) $(MFLAGS) clean
|
||||
cd leim && $(MAKE) $(MFLAGS) clean
|
||||
cd nextstep && $(MAKE) $(MFLAGS) clean
|
||||
|
||||
### `bootclean'
|
||||
|
@ -878,7 +857,7 @@ distclean: FRC
|
|||
cd leim && $(MAKE) $(MFLAGS) distclean
|
||||
cd lisp && $(MAKE) $(MFLAGS) distclean
|
||||
cd nextstep && $(MAKE) $(MFLAGS) distclean
|
||||
for dir in test/automated admin/unidata; do \
|
||||
for dir in test/automated admin/grammars admin/unidata; do \
|
||||
[ ! -d $$dir ] || (cd $$dir && $(MAKE) $(MFLAGS) distclean); \
|
||||
done
|
||||
${top_distclean}
|
||||
|
@ -897,10 +876,10 @@ bootstrap-clean: FRC
|
|||
-cd doc/misc && $(MAKE) $(MFLAGS) maintainer-clean
|
||||
-cd doc/lispref && $(MAKE) $(MFLAGS) maintainer-clean
|
||||
-cd doc/lispintro && $(MAKE) $(MFLAGS) maintainer-clean
|
||||
cd leim && $(MAKE) $(MFLAGS) maintainer-clean
|
||||
cd leim && $(MAKE) $(MFLAGS) bootstrap-clean
|
||||
cd lisp && $(MAKE) $(MFLAGS) bootstrap-clean
|
||||
cd nextstep && $(MAKE) $(MFLAGS) maintainer-clean
|
||||
for dir in test/automated admin/unidata; do \
|
||||
for dir in test/automated admin/grammars admin/unidata; do \
|
||||
[ ! -d $$dir ] || (cd $$dir && $(MAKE) $(MFLAGS) bootstrap-clean); \
|
||||
done
|
||||
[ ! -f config.log ] || mv -f config.log config.log~
|
||||
|
@ -922,8 +901,9 @@ top_maintainer_clean=\
|
|||
rm -fr autom4te.cache
|
||||
maintainer-clean: bootstrap-clean FRC
|
||||
cd src && $(MAKE) $(MFLAGS) maintainer-clean
|
||||
cd leim && $(MAKE) $(MFLAGS) maintainer-clean
|
||||
cd lisp && $(MAKE) $(MFLAGS) maintainer-clean
|
||||
for dir in test/automated admin/unidata; do \
|
||||
for dir in test/automated admin/grammars admin/unidata; do \
|
||||
[ ! -d $$dir ] || (cd $$dir && $(MAKE) $(MFLAGS) maintainer-clean); \
|
||||
done
|
||||
${top_maintainer_clean}
|
||||
|
@ -1088,5 +1068,4 @@ check-declare:
|
|||
echo "You must build Emacs to use this command"; \
|
||||
exit 1; \
|
||||
fi
|
||||
cd leim && $(MAKE) $(MFLAGS) $@
|
||||
cd lisp && $(MAKE) $(MFLAGS) $@
|
||||
|
|
7
README
7
README
|
@ -64,9 +64,10 @@ There are several subdirectories:
|
|||
its primitives, the redisplay code, and some basic editing
|
||||
functions).
|
||||
`lisp' holds the Emacs Lisp code for Emacs (most everything else).
|
||||
`leim' holds the library of Emacs input methods, Lisp code and
|
||||
auxiliary data files required to type international characters
|
||||
which can't be directly produced by your keyboard.
|
||||
`leim' holds the original source files for the generated files
|
||||
in lisp/leim. These form the library of Emacs input methods,
|
||||
required to type international characters that can't be
|
||||
directly produced by your keyboard.
|
||||
`lib' holds source code for libraries used by Emacs and its utilities
|
||||
`lib-src' holds the source code for some utility programs for use by or
|
||||
with Emacs, like movemail and etags.
|
||||
|
|
|
@ -1,3 +1,51 @@
|
|||
2013-12-04 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* unidata/unidata-gen.el (unidata-prop-alist): Update bidi-class
|
||||
to include the new isolate-related classes introduced with Unicode
|
||||
v6.3.
|
||||
(unidata-encode-val): Accept an additional optional argument, a
|
||||
warning message to emit when UnicodeData.txt defines bidi-class
|
||||
values that are not in unidata-prop-alist. Add a comment
|
||||
explaining what should maintainers do if/when such a warning ever
|
||||
appears.
|
||||
(unidata-gen-table): Call unidata-encode-val with 3rd arg non-nil
|
||||
when generating uni-bidi.el.
|
||||
|
||||
2013-12-01 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* unidata/Makefile.in (${DSTDIR}/charprop.el):
|
||||
Ensure output files are writable.
|
||||
|
||||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* grammars/Makefile.in: Ensure output files are writable.
|
||||
|
||||
2013-11-30 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* charsets/mule-charsets.el: Rewritten to work in Emacs 23 and
|
||||
later. (Bug#16007)
|
||||
|
||||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
Stop keeping (most) generated cedet grammar files in the repository.
|
||||
* grammars/README: Remove.
|
||||
* grammars/Makefile.in: New file.
|
||||
* grammars/c.by, grammars/java-tags.wy, grammars/js.wy:
|
||||
* grammars/python.wy: Update declarations to match generated outputs.
|
||||
|
||||
2013-11-28 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* unidata/unidata-gen.el (unidata-gen-files):
|
||||
Disable autoloads in generated files.
|
||||
|
||||
2013-11-27 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* unidata/Makefile.in (all, install, clean, bootstrap-clean)
|
||||
(distclean, maintainer-clean): Declare as PHONY.
|
||||
(compile, extraclean): New.
|
||||
(${DSTDIR}/charprop.el): Depend on source files rather than
|
||||
intermediate products.
|
||||
|
||||
2013-11-11 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* unidata/BidiMirroring.txt, unidata/UnicodeData.txt: Update to 6.3.0.
|
||||
|
|
|
@ -19,20 +19,32 @@
|
|||
;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
|
||||
(if (not (or (and (= emacs-major-version 21) (= emacs-minor-version 4))
|
||||
(= emacs-major-version 22)))
|
||||
(error "Use Emacs of version 21.4 or any of version 22"))
|
||||
;; For the record: the old, pre-v23 code was this:
|
||||
;; (if (not (or (and (= emacs-major-version 21) (= emacs-minor-version 4))
|
||||
;; (= emacs-major-version 22)))
|
||||
;; (error "Use Emacs of version 21.4 or any of version 22"))
|
||||
;;
|
||||
;; (defun func (start end)
|
||||
;; (while (<= start end)
|
||||
;; (let ((split (split-char start))
|
||||
;; (unicode (encode-char start 'ucs)))
|
||||
;; (if unicode
|
||||
;; (if (nth 2 split)
|
||||
;; (insert (format "0x%02X%02X 0x%04X\n"
|
||||
;; (nth 1 split) (nth 2 split) unicode))
|
||||
;; (insert (format "0x%02X 0x%04X\n" (nth 1 split) unicode)))))
|
||||
;; (setq start (1+ start))))
|
||||
|
||||
(defun func (start end)
|
||||
(while (<= start end)
|
||||
(let ((split (split-char start))
|
||||
(unicode (encode-char start 'ucs)))
|
||||
(if unicode
|
||||
(if (nth 2 split)
|
||||
(insert (format "0x%02X%02X 0x%04X\n"
|
||||
(nth 1 split) (nth 2 split) unicode))
|
||||
(insert (format "0x%02X 0x%04X\n" (nth 1 split) unicode)))))
|
||||
(setq start (1+ start))))
|
||||
(defun func (range charset)
|
||||
(let ((start (car range))
|
||||
(end (cdr range)))
|
||||
(while (and (<= start end) (<= start #x10ffff))
|
||||
(let ((ch (encode-char start charset)))
|
||||
(if ch
|
||||
(if (> ch 256)
|
||||
(insert (format "0x%04X 0x%04X\n" ch start))
|
||||
(insert (format "0x%02X 0x%04X\n" ch start)))))
|
||||
(setq start (1+ start)))))
|
||||
|
||||
(defconst charset-alist
|
||||
'(("MULE-ethiopic.map" . ethiopic)
|
||||
|
@ -51,6 +63,8 @@
|
|||
(dolist (elt charset-alist)
|
||||
(with-temp-buffer
|
||||
(insert header)
|
||||
(map-charset-chars 'func (cdr elt))
|
||||
(write-file (car elt))))
|
||||
(map-charset-chars 'func (cdr elt) (cdr elt))
|
||||
(sort-lines nil (point-min) (point-max))
|
||||
(let ((coding-system-for-write 'unix))
|
||||
(write-file (car elt)))))
|
||||
|
||||
|
|
113
admin/grammars/Makefile.in
Normal file
113
admin/grammars/Makefile.in
Normal file
|
@ -0,0 +1,113 @@
|
|||
### @configure_input@
|
||||
|
||||
## Copyright (C) 2013 Free Software Foundation, Inc.
|
||||
|
||||
## This file is part of GNU Emacs.
|
||||
|
||||
## GNU Emacs is free software: you can redistribute it and/or modify
|
||||
## it under the terms of the GNU General Public License as published by
|
||||
## the Free Software Foundation, either version 3 of the License, or
|
||||
## (at your option) any later version.
|
||||
|
||||
## GNU Emacs is distributed in the hope that it will be useful,
|
||||
## but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
## GNU General Public License for more details.
|
||||
|
||||
## You should have received a copy of the GNU General Public License
|
||||
## along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
### Commentary:
|
||||
|
||||
## This directory contains grammar files in Bison and Wisent,
|
||||
## used to generate the parser data in the lisp/cedet directory.
|
||||
|
||||
SHELL = @SHELL@
|
||||
|
||||
srcdir = @srcdir@
|
||||
top_srcdir = @top_srcdir@
|
||||
top_builddir = @top_builddir@
|
||||
|
||||
EMACS = ${top_builddir}/src/emacs
|
||||
emacs = EMACSLOADPATH= "${EMACS}" -batch --no-site-file --no-site-lisp
|
||||
|
||||
make_bovine = ${emacs} -l semantic/bovine/grammar -f bovine-batch-make-parser
|
||||
make_wisent = ${emacs} -l semantic/wisent/grammar -f wisent-batch-make-parser
|
||||
|
||||
cedetdir = ${top_srcdir}/lisp/cedet
|
||||
bovinedir = ${cedetdir}/semantic/bovine
|
||||
wisentdir = ${cedetdir}/semantic/wisent
|
||||
|
||||
BOVINE = \
|
||||
${bovinedir}/c-by.el \
|
||||
${bovinedir}/make-by.el \
|
||||
${bovinedir}/scm-by.el
|
||||
|
||||
## FIXME Should include this one too:
|
||||
## ${cedetdir}/semantic/grammar-wy.el
|
||||
## but semantic/grammar.el (which is what we use to generate grammar-wy.el)
|
||||
## requires it!
|
||||
WISENT = \
|
||||
${wisentdir}/javat-wy.el \
|
||||
${wisentdir}/js-wy.el \
|
||||
${wisentdir}/python-wy.el \
|
||||
${cedetdir}/srecode/srt-wy.el
|
||||
|
||||
ALL = ${BOVINE} ${WISENT}
|
||||
|
||||
.PHONY: all bovine wisent
|
||||
|
||||
all: ${ALL}
|
||||
|
||||
bovine: ${BOVINE}
|
||||
|
||||
wisent: ${WISENT}
|
||||
|
||||
|
||||
${bovinedir}/c-by.el: ${srcdir}/c.by
|
||||
[ ! -f "$@" ] || chmod +w "$@"
|
||||
${make_bovine} -o "$@" ${srcdir}/c.by
|
||||
|
||||
${bovinedir}/make-by.el: ${srcdir}/make.by
|
||||
[ ! -f "$@" ] || chmod +w "$@"
|
||||
${make_bovine} -o "$@" ${srcdir}/make.by
|
||||
|
||||
${bovinedir}/scm-by.el: ${srcdir}/scheme.by
|
||||
[ ! -f "$@" ] || chmod +w "$@"
|
||||
${make_bovine} -o "$@" ${srcdir}/scheme.by
|
||||
|
||||
|
||||
${cedetdir}/semantic/grammar-wy.el: ${srcdir}/grammar.wy
|
||||
[ ! -f "$@" ] || chmod +w "$@"
|
||||
${make_wisent} -o "$@" ${srcdir}/grammar.wy
|
||||
|
||||
${wisentdir}/javat-wy.el: ${srcdir}/java-tags.wy
|
||||
[ ! -f "$@" ] || chmod +w "$@"
|
||||
${make_wisent} -o "$@" ${srcdir}/java-tags.wy
|
||||
|
||||
${wisentdir}/js-wy.el: ${srcdir}/js.wy
|
||||
[ ! -f "$@" ] || chmod +w "$@"
|
||||
${make_wisent} -o "$@" ${srcdir}/js.wy
|
||||
|
||||
${wisentdir}/python-wy.el: ${srcdir}/python.wy
|
||||
[ ! -f "$@" ] || chmod +w "$@"
|
||||
${make_wisent} -o "$@" ${srcdir}/python.wy
|
||||
|
||||
${cedetdir}/srecode/srt-wy.el: ${srcdir}/srecode-template.wy
|
||||
[ ! -f "$@" ] || chmod +w "$@"
|
||||
${make_wisent} -o "$@" ${srcdir}/srecode-template.wy
|
||||
|
||||
|
||||
.PHONY: distclean bootstrap-clean maintainer-clean extraclean
|
||||
|
||||
distclean:
|
||||
rm -f Makefile
|
||||
|
||||
bootstrap-clean maintainer-clean: distclean
|
||||
|
||||
## We do not normally delete the generated files, even in bootstrap.
|
||||
## Creating them does not take long, so we could easily change this.
|
||||
extraclean:
|
||||
rm -f ${ALL}
|
||||
|
||||
# Makefile.in ends here
|
|
@ -1,11 +0,0 @@
|
|||
This directory contains grammar files in Bison and Wisent, used to
|
||||
generate the parser data in the lisp/semantic/bovine/ and
|
||||
lisp/semantic/wisent/ directories. You can run the parser generators
|
||||
with
|
||||
|
||||
emacs -batch -Q -l semantic/bovine/grammar -f bovine-make-parsers
|
||||
emacs -batch -Q -l semantic/wisent/grammar -f wisent-make-parsers
|
||||
|
||||
Currently, the parser files in lisp/ are not generated directly from
|
||||
these grammar files when making Emacs. This state of affairs, and the
|
||||
contents of this directory, will change in a future version of Emacs.
|
|
@ -41,9 +41,13 @@
|
|||
%provide semantic/bovine/c-by
|
||||
|
||||
%{
|
||||
(declare-function semantic-c-reconstitute-token "semantic/bovine/c")
|
||||
(declare-function semantic-c-reconstitute-template "semantic/bovine/c")
|
||||
(declare-function semantic-expand-c-tag "semantic/bovine/c")
|
||||
(declare-function semantic-c-reconstitute-token "semantic/bovine/c"
|
||||
(tokenpart declmods typedecl))
|
||||
(declare-function semantic-c-reconstitute-template "semantic/bovine/c"
|
||||
(tag specifier))
|
||||
(declare-function semantic-expand-c-tag "semantic/bovine/c" (tag))
|
||||
(declare-function semantic-parse-region "semantic"
|
||||
(start end &optional nonterminal depth returnonerror))
|
||||
}
|
||||
|
||||
%languagemode c-mode c++-mode
|
||||
|
|
|
@ -25,6 +25,11 @@
|
|||
%package wisent-java-tags-wy
|
||||
%provide semantic/wisent/javat-wy
|
||||
|
||||
%{
|
||||
(declare-function semantic-parse-region "semantic"
|
||||
(start end &optional nonterminal depth returnonerror))
|
||||
}
|
||||
|
||||
%languagemode java-mode
|
||||
|
||||
;; The default start symbol
|
||||
|
|
|
@ -59,6 +59,12 @@
|
|||
|
||||
%package wisent-javascript-jv-wy
|
||||
%provide semantic/wisent/js-wy
|
||||
|
||||
%{
|
||||
(declare-function semantic-parse-region "semantic"
|
||||
(start end &optional nonterminal depth returnonerror))
|
||||
}
|
||||
|
||||
;; JAVE I prefere ecmascript-mode
|
||||
%languagemode ecmascript-mode javascript-mode
|
||||
|
||||
|
|
|
@ -91,8 +91,12 @@
|
|||
%provide semantic/wisent/python-wy
|
||||
|
||||
%{
|
||||
(declare-function wisent-python-reconstitute-function-tag "semantic/wisent/python")
|
||||
(declare-function wisent-python-reconstitute-class-tag "semantic/wisent/python")
|
||||
(declare-function wisent-python-reconstitute-function-tag
|
||||
"semantic/wisent/python" (tag suite))
|
||||
(declare-function wisent-python-reconstitute-class-tag "semantic/wisent/python"
|
||||
(tag))
|
||||
(declare-function semantic-parse-region "semantic"
|
||||
(start end &optional nonterminal depth returnonerror))
|
||||
}
|
||||
|
||||
%languagemode python-mode
|
||||
|
|
|
@ -31,6 +31,8 @@ EMACS = ${top_builddir}/src/emacs
|
|||
DSTDIR = ${top_srcdir}/lisp/international
|
||||
emacs = "${EMACS}" -batch --no-site-file --no-site-lisp
|
||||
|
||||
.PHONY: all compile install
|
||||
|
||||
all: ${DSTDIR}/charprop.el
|
||||
|
||||
.el.elc:
|
||||
|
@ -39,7 +41,16 @@ all: ${DSTDIR}/charprop.el
|
|||
unidata.txt: ${srcdir}/UnicodeData.txt
|
||||
sed -e 's/\([^;]*\);\(.*\)/(#x\1 "\2")/' -e 's/;/" "/g' < ${srcdir}/UnicodeData.txt > $@
|
||||
|
||||
${DSTDIR}/charprop.el: ${srcdir}/unidata-gen.elc unidata.txt
|
||||
compile: ${srcdir}/unidata-gen.elc
|
||||
|
||||
## Depend on .el rather than .elc so as not to needlessly rebuild
|
||||
## uni-*.el files just because .elc is missing.
|
||||
## Same for UnicodeData.txt v unidata.txt.
|
||||
${DSTDIR}/charprop.el: ${srcdir}/unidata-gen.el ${srcdir}/UnicodeData.txt
|
||||
${MAKE} ${MFLAGS} compile unidata.txt EMACS="${EMACS}"
|
||||
-if [ -f "$@" ]; then \
|
||||
cd ${DSTDIR} && chmod +w charprop.el `sed -n 's/^;; FILE: //p' < charprop.el`; \
|
||||
fi
|
||||
${emacs} -L ${srcdir} -l unidata-gen -f unidata-gen-files \
|
||||
${srcdir} "${DSTDIR}"
|
||||
|
||||
|
@ -48,6 +59,8 @@ charprop.el: ${srcdir}/unidata-gen.elc unidata.txt
|
|||
${emacs} -L ${srcdir} -l unidata-gen -f unidata-gen-files \
|
||||
${srcdir}
|
||||
|
||||
.PHONY: clean bootstrap-clean distclean maintainer-clean extraclean
|
||||
|
||||
install: charprop.el
|
||||
cp charprop.el ${DSTDIR}
|
||||
cp `sed -n 's/^;; FILE: //p' < charprop.el` ${DSTDIR}
|
||||
|
@ -61,6 +74,15 @@ clean:
|
|||
bootstrap-clean: clean
|
||||
|
||||
distclean: clean
|
||||
-rm -f ./Makefile
|
||||
rm -f Makefile
|
||||
|
||||
maintainer-clean: distclean
|
||||
|
||||
## Do not remove these files, even in a bootstrap, because they rarely
|
||||
## change and it slows down bootstrap (a tiny bit).
|
||||
## Cf leim/ja-dic (which is much slower).
|
||||
extraclean:
|
||||
if test -f ${DSTDIR}/charprop.el; then \
|
||||
(cd ${DSTDIR} && rm -f `sed -n 's/^;; FILE: //p' < charprop.el`); \
|
||||
rm -f ${DSTDIR}/charprop.el; \
|
||||
fi
|
||||
|
|
|
@ -194,8 +194,8 @@ Property value is an integer."
|
|||
4 unidata-gen-table-symbol "uni-bidi.el"
|
||||
"Unicode bidi class.
|
||||
Property value is one of the following symbols:
|
||||
L, LRE, LRO, R, AL, RLE, RLO, PDF, EN, ES, ET,
|
||||
AN, CS, NSM, BN, B, S, WS, ON"
|
||||
L, LRE, LRO, LRI, R, AL, RLE, RLO, RLI, FSI, PDF, PDI,
|
||||
EN, ES, ET, AN, CS, NSM, BN, B, S, WS, ON"
|
||||
unidata-describe-bidi-class
|
||||
;; The assignment of default values to blocks of code points
|
||||
;; follows the file DerivedBidiClass.txt from the Unicode
|
||||
|
@ -205,7 +205,8 @@ Property value is one of the following symbols:
|
|||
(#xFB1D #xFB4F R) (#x10800 #x10FFF R) (#x1E800 #x1EFFF R))
|
||||
;; The order of elements must be in sync with bidi_type_t in
|
||||
;; src/dispextern.h.
|
||||
(L R EN AN BN B AL LRE LRO RLE RLO PDF ES ET CS NSM S WS ON))
|
||||
(L R EN AN BN B AL LRE LRO RLE RLO PDF LRI RLI FSI PDI
|
||||
ES ET CS NSM S WS ON))
|
||||
(decomposition
|
||||
5 unidata-gen-table-decomposition "uni-decomposition.el"
|
||||
"Unicode decomposition mapping.
|
||||
|
@ -397,12 +398,17 @@ is the character itself.")))
|
|||
;; If VAL is one of VALn, just return n.
|
||||
;; Otherwise, VAL-LIST is modified to this:
|
||||
;; ((nil . 0) (VAL1 . 1) (VAL2 . 2) ... (VAL . n+1))
|
||||
;;
|
||||
;; WARN is an optional warning to display when the value list is
|
||||
;; extended, for property values that need to be in sync with other
|
||||
;; parts of Emacs; currently only used for bidi-class.
|
||||
|
||||
(defun unidata-encode-val (val-list val)
|
||||
(defun unidata-encode-val (val-list val &optional warn)
|
||||
(let ((slot (assoc val val-list))
|
||||
val-code)
|
||||
(if slot
|
||||
(cdr slot)
|
||||
(if warn (message warn val))
|
||||
(setq val-code (length val-list))
|
||||
(nconc val-list (list (cons val val-code)))
|
||||
val-code)))
|
||||
|
@ -413,6 +419,16 @@ is the character itself.")))
|
|||
(let ((table (make-char-table 'char-code-property-table))
|
||||
(prop-idx (unidata-prop-index prop))
|
||||
(vec (make-vector 128 0))
|
||||
;; When this warning is printed, there's a need to make the
|
||||
;; following changes:
|
||||
;; (1) update unidata-prop-alist with the new bidi-class values;
|
||||
;; (2) extend bidi_type_t enumeration on src/dispextern.h to
|
||||
;; include the new classes;
|
||||
;; (3) possibly update the assertion in bidi.c:bidi_check_type; and
|
||||
;; (4) possibly update the switch cases in
|
||||
;; bidi.c:bidi_get_type and bidi.c:bidi_get_category.
|
||||
(bidi-warning "\
|
||||
** Found new bidi-class '%s', please update bidi.c and dispextern.h")
|
||||
tail elt range val val-code idx slot
|
||||
prev-range-data)
|
||||
(setq val-list (cons nil (copy-sequence val-list)))
|
||||
|
@ -438,7 +454,9 @@ is the character itself.")))
|
|||
(setq elt (car tail) tail (cdr tail))
|
||||
(setq range (car elt)
|
||||
val (funcall val-func (nth prop-idx elt)))
|
||||
(setq val-code (if val (unidata-encode-val val-list val)))
|
||||
(setq val-code (if val (unidata-encode-val val-list val
|
||||
(and (eq prop 'bidi-class)
|
||||
bidi-warning))))
|
||||
(if (consp range)
|
||||
(when val-code
|
||||
(set-char-table-range table range val-code)
|
||||
|
@ -486,7 +504,9 @@ is the character itself.")))
|
|||
(setq new-val (funcall val-func (nth prop-idx elt)))
|
||||
(if (not (eq val new-val))
|
||||
(setq val new-val
|
||||
val-code (if val (unidata-encode-val val-list val))))
|
||||
val-code (if val (unidata-encode-val
|
||||
val-list val (and (eq prop 'bidi-class)
|
||||
bidi-warning)))))
|
||||
(if val-code
|
||||
(aset vec (- range start) val-code))
|
||||
(setq tail (cdr tail)))
|
||||
|
@ -1241,6 +1261,7 @@ is the character itself.")))
|
|||
";; coding: utf-8\n"
|
||||
";; version-control: never\n"
|
||||
";; no-byte-compile: t\n"
|
||||
";; no-update-autoloads: t\n"
|
||||
";; End:\n\n"
|
||||
(format ";; %s ends here\n" basename)))
|
||||
(write-file file)
|
||||
|
@ -1250,6 +1271,7 @@ is the character itself.")))
|
|||
";; coding: utf-8\n"
|
||||
";; version-control: never\n"
|
||||
";; no-byte-compile: t\n"
|
||||
";; no-update-autoloads: t\n"
|
||||
";; End:\n\n"
|
||||
(format ";; %s ends here\n"
|
||||
(file-name-nondirectory charprop-file))))))
|
||||
|
|
170
build-aux/msys-to-w32
Executable file
170
build-aux/msys-to-w32
Executable file
|
@ -0,0 +1,170 @@
|
|||
#!/bin/sh
|
||||
# Take a list of MSYS-compatible paths and convert them to native
|
||||
# MS-Windows format.
|
||||
# Status is zero if successful, nonzero otherwise.
|
||||
|
||||
# Copyright (C) 2013 Free Software Foundation, Inc.
|
||||
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# Take only the basename from the full pathname
|
||||
me=${0//*\//}
|
||||
|
||||
usage="usage: ${me} PATHLIST [MUSTEXIST] [SEPARATOR [SEPARATOR2]]"
|
||||
|
||||
help="$usage
|
||||
or: ${me} OPTION
|
||||
|
||||
Convert MSYS-compatible paths to MS-Windows native format.
|
||||
|
||||
PATHLIST should be a list of paths separated by SEPARATOR. This list
|
||||
will be written to the standard output after performing the following
|
||||
transformations:
|
||||
1. Discard empty paths.
|
||||
2. Replace backslashes with forward slashes.
|
||||
3. Replace two consecutive slashes with single ones.
|
||||
4. Translate to Windows-native format those paths that are not in such
|
||||
format already. The translated paths will not end with a slash,
|
||||
except for root directories (e.g. 'c:/' or 'c:/foo'). Paths
|
||||
starting with '%emacs_dir%' will not be translated.
|
||||
5. Escape with backslashes every occurrence of SEPARATOR2 within the paths.
|
||||
6. Concatenate the translated paths with SEPARATOR2.
|
||||
|
||||
If MUSTEXIST is 'Y' or not supplied, then each path in PATHLIST must
|
||||
exist. Otherwise, only some part of each path is required to exist
|
||||
(the deepest existing subpath will be translated and the remainder
|
||||
concatenated to the translation).
|
||||
|
||||
If SEPARATOR is not supplied, PATHLIST will be regarded as a single
|
||||
path.
|
||||
|
||||
If SEPARATOR2 is not supplied, it will take the same value as
|
||||
SEPARATOR.
|
||||
|
||||
Options:
|
||||
--help display this help and exit
|
||||
|
||||
Report bugs to <bug-gnu-emacs@gnu.org>."
|
||||
|
||||
for arg
|
||||
do
|
||||
case $arg in
|
||||
--help | --hel | --he | --h)
|
||||
exec echo "$help" ;;
|
||||
--)
|
||||
shift
|
||||
break ;;
|
||||
-*)
|
||||
echo "${me}: invalid option: $arg" >&2
|
||||
exit 1 ;;
|
||||
*)
|
||||
break ;;
|
||||
esac
|
||||
done
|
||||
|
||||
{ test $# -ge 1 && test $# -le 4; } ||
|
||||
{ echo "${me}: $usage" >&2; exit 1; }
|
||||
|
||||
# Arguments
|
||||
pathlist="$1"
|
||||
mustexist="${2:-Y}"
|
||||
separator="$3"
|
||||
separator2="${4:-${separator}}"
|
||||
|
||||
# Split pathlist into its path components
|
||||
if test -n "$separator"
|
||||
then
|
||||
IFS=${separator} patharray=( $pathlist )
|
||||
else
|
||||
patharray=( "$pathlist" )
|
||||
fi
|
||||
|
||||
w32pathlist=""
|
||||
|
||||
for p in "${patharray[@]}"
|
||||
do
|
||||
# Skip empty paths
|
||||
test "$p" = "" && continue
|
||||
|
||||
# Replace '\' with '/' and '//' with '/'
|
||||
p="${p//\\//}"
|
||||
p="${p//\/\///}"
|
||||
|
||||
if test "${p:0:11}" = "%emacs_dir%"
|
||||
then
|
||||
# Paths starting with "%emacs_dir%" will not be translated
|
||||
w32p=$p
|
||||
elif test -d "$p"
|
||||
then
|
||||
# The path exists, so just translate it
|
||||
w32p=`cd "$p" && pwd -W`
|
||||
else
|
||||
# The path does not exist. So, try to guess the
|
||||
# Windows-native translation, by looking for the deepest
|
||||
# existing directory in this path, and then translating the
|
||||
# existing part and concatenating the remainder.
|
||||
|
||||
test "${mustexist}" = "Y" &&
|
||||
{ echo "${me}: invalid path: $p" >&2; exit 1; }
|
||||
|
||||
p1=$p
|
||||
IFS=/ pcomponents=( $p )
|
||||
|
||||
for (( i=${#pcomponents[@]}-1 ; i>=0 ; i-- ))
|
||||
do
|
||||
|
||||
if test "${pcomponents[i]}" = ""
|
||||
then
|
||||
# The path component is empty. This can only mean
|
||||
# that the path starts with "/" and all components
|
||||
# have been stripped out already. So in this case we
|
||||
# want to test with the MSYS root directory
|
||||
p1="/"
|
||||
else
|
||||
p1="${p1%/}"
|
||||
p1="${p1%${pcomponents[i]}}"
|
||||
fi
|
||||
|
||||
if test -d "${p1}"
|
||||
then
|
||||
|
||||
# Existing path found
|
||||
|
||||
# Translate the existing part and concatenate the
|
||||
# remainder (ensuring that only one slash is used in
|
||||
# the join, and no trailing slash is left)
|
||||
w32p1=`cd "${p1}" && pwd -W`
|
||||
remainder="${p#${p1}}"
|
||||
remainder="${remainder#/}"
|
||||
remainder="${remainder%/}"
|
||||
w32p="${w32p1%/}/${remainder}"
|
||||
|
||||
break
|
||||
fi
|
||||
|
||||
done
|
||||
|
||||
# If no existing directory was found, error out
|
||||
test -e "${p1}" ||
|
||||
{ echo "${me}: invalid path: ${p}" >&2; exit 1; }
|
||||
fi
|
||||
|
||||
# Concatenate the translated path to the translated pathlist
|
||||
test "${w32pathlist}" = "" || w32pathlist="${w32pathlist}${separator2}"
|
||||
w32pathlist="${w32pathlist}${w32p//${separator2}/\\${separator2}}"
|
||||
|
||||
done
|
||||
|
||||
# Write the translated pathlist to the standard output
|
||||
printf "%s" "${w32pathlist}"
|
83
configure.ac
83
configure.ac
|
@ -80,8 +80,7 @@ dnl hence the single quotes. This is per the GNU coding standards, see
|
|||
dnl (autoconf) Installation Directory Variables
|
||||
dnl See also epaths.h below.
|
||||
lispdir='${datadir}/emacs/${version}/lisp'
|
||||
leimdir='${datadir}/emacs/${version}/leim'
|
||||
standardlisppath='${lispdir}:${leimdir}'
|
||||
standardlisppath='${lispdir}'
|
||||
locallisppath='${datadir}/emacs/${version}/site-lisp:'\
|
||||
'${datadir}/emacs/site-lisp'
|
||||
lisppath='${locallisppath}:${standardlisppath}'
|
||||
|
@ -1683,7 +1682,6 @@ if test "${HAVE_NS}" = yes; then
|
|||
infodir="\${ns_appresdir}/info"
|
||||
mandir="\${ns_appresdir}/man"
|
||||
lispdir="\${ns_appresdir}/lisp"
|
||||
leimdir="\${ns_appresdir}/leim"
|
||||
INSTALL_ARCH_INDEP_EXTRA=
|
||||
fi
|
||||
|
||||
|
@ -1868,9 +1866,6 @@ to configure.])
|
|||
fi
|
||||
fi
|
||||
|
||||
### We always support menus.
|
||||
HAVE_MENUS=yes
|
||||
|
||||
# Does the opsystem file prohibit the use of the GNU malloc?
|
||||
# Assume not, until told otherwise.
|
||||
GNU_MALLOC=yes
|
||||
|
@ -3837,12 +3832,22 @@ else
|
|||
AC_DEFINE(NULL_DEVICE, ["/dev/null"])
|
||||
fi
|
||||
|
||||
AH_TEMPLATE(SEPCHAR, [Character that separates PATH elements.])
|
||||
if test "${opsys}" = "mingw32"; then
|
||||
AC_DEFINE(SEPCHAR, [';'])
|
||||
SEPCHAR=';'
|
||||
else
|
||||
AC_DEFINE(SEPCHAR, [':'])
|
||||
SEPCHAR=':'
|
||||
fi
|
||||
AC_DEFINE_UNQUOTED(SEPCHAR, ['$SEPCHAR'], [Character that separates PATH elements.])
|
||||
dnl This is for MinGW, and is used in test/automated/Makefile.in.
|
||||
dnl The MSYS Bash has heuristics for replacing ':' with ';' when it
|
||||
dnl decides that a command-line argument to be passed to a MinGW program
|
||||
dnl is a PATH-style list of directories. But that heuristics plays it
|
||||
dnl safe, and only does the replacement when it is _absolutely_ sure it
|
||||
dnl sees a colon-separated list of file names; e.g. ":." is left alone,
|
||||
dnl which breaks in-tree builds. So we do this manually instead.
|
||||
dnl Note that we cannot rely on PATH_SEPARATOR, as that one will always
|
||||
dnl be computed as ':' in MSYS Bash.
|
||||
AC_SUBST(SEPCHAR)
|
||||
|
||||
dnl Everybody supports this, except MS-DOS.
|
||||
AC_DEFINE(subprocesses, 1, [Define to enable asynchronous subprocesses.])
|
||||
|
@ -4490,7 +4495,6 @@ AC_SUBST(libexecdir)
|
|||
AC_SUBST(mandir)
|
||||
AC_SUBST(infodir)
|
||||
AC_SUBST(lispdir)
|
||||
AC_SUBST(leimdir)
|
||||
AC_SUBST(standardlisppath)
|
||||
AC_SUBST(locallisppath)
|
||||
AC_SUBST(lisppath)
|
||||
|
@ -4598,61 +4602,29 @@ AC_SUBST(TOOLKIT_LIBW)
|
|||
if test "${opsys}" != "mingw32"; then
|
||||
if test "$USE_X_TOOLKIT" = "none"; then
|
||||
LIBXT_OTHER="\$(LIBXSM)"
|
||||
OLDXMENU_TARGET="really-oldXMenu"
|
||||
else
|
||||
LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
|
||||
OLDXMENU_TARGET="really-lwlib"
|
||||
fi
|
||||
fi
|
||||
AC_SUBST(LIBXT_OTHER)
|
||||
|
||||
## The X Menu stuff is present in the X10 distribution, but missing
|
||||
## from X11. If we have X10, just use the installed library;
|
||||
## otherwise, use our own copy.
|
||||
if test "${HAVE_X11}" = "yes" ; then
|
||||
AC_DEFINE(HAVE_X11, 1,
|
||||
[Define to 1 if you want to use version 11 of X windows.
|
||||
Otherwise, Emacs expects to use version 10.])
|
||||
|
||||
if test "$USE_X_TOOLKIT" = "none"; then
|
||||
OLDXMENU="\${oldXMenudir}/libXMenu11.a"
|
||||
else
|
||||
OLDXMENU="\${lwlibdir}/liblw.a"
|
||||
fi
|
||||
LIBXMENU="\$(OLDXMENU)"
|
||||
[Define to 1 if you want to use version 11 of X windows.])
|
||||
LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
|
||||
OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
|
||||
else
|
||||
## For a syntactically valid Makefile; not actually used for anything.
|
||||
## See comments in src/Makefile.in.
|
||||
OLDXMENU=nothing
|
||||
## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
|
||||
if test "${HAVE_X_WINDOWS}" = "yes"; then
|
||||
LIBXMENU="-lXMenu"
|
||||
else
|
||||
LIBXMENU=
|
||||
fi
|
||||
LIBX_OTHER=
|
||||
OLDXMENU_DEPS=
|
||||
fi
|
||||
|
||||
if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
|
||||
OLDXMENU_TARGET=
|
||||
OLDXMENU=nothing
|
||||
LIBXMENU=
|
||||
OLDXMENU_DEPS=
|
||||
fi
|
||||
|
||||
AC_SUBST(OLDXMENU_TARGET)
|
||||
AC_SUBST(OLDXMENU)
|
||||
AC_SUBST(LIBXMENU)
|
||||
AC_SUBST(LIBX_OTHER)
|
||||
AC_SUBST(OLDXMENU_DEPS)
|
||||
|
||||
if test "${HAVE_MENUS}" = "yes" ; then
|
||||
AC_DEFINE(HAVE_MENUS, 1,
|
||||
[Define to 1 if you have mouse menus. (This is supported in all configurations, but the option to specify it remains.)])
|
||||
if test "$HAVE_GTK" = yes || test "$HAVE_X11" != yes; then
|
||||
LIBXMENU=
|
||||
elif test "$USE_X_TOOLKIT" = none; then
|
||||
LIBXMENU='$(oldXMenudir)/libXMenu11.a'
|
||||
else
|
||||
LIBXMENU='$(lwlibdir)/liblw.a'
|
||||
fi
|
||||
AC_SUBST(LIBXMENU)
|
||||
|
||||
if test "${GNU_MALLOC}" = "yes" ; then
|
||||
AC_DEFINE(GNU_MALLOC, 1,
|
||||
|
@ -4999,13 +4971,12 @@ if test -f "$srcdir/$opt_makefile.in"; then
|
|||
fi
|
||||
|
||||
|
||||
dnl admin/ may or may not be present.
|
||||
opt_makefile=admin/unidata/Makefile
|
||||
|
||||
if test -f "$srcdir/$opt_makefile.in"; then
|
||||
SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
|
||||
dnl The admin/ directory used to be excluded from tarfiles.
|
||||
if test -d $srcdir/admin; then
|
||||
SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES admin/unidata/Makefile admin/grammars/Makefile"
|
||||
AC_CONFIG_FILES([admin/unidata/Makefile])
|
||||
fi
|
||||
AC_CONFIG_FILES([admin/grammars/Makefile])
|
||||
fi dnl -d admin
|
||||
|
||||
|
||||
SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
|
||||
|
|
|
@ -1,3 +1,21 @@
|
|||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* Makefile.in (distclean): Remove Makefile.
|
||||
|
||||
2013-11-29 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* buffers.texi (Icomplete): Rename from Iswitchb and
|
||||
rewrite accordingly.
|
||||
|
||||
2013-11-23 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* cmdargs.texi (General Variables):
|
||||
Empty elements in EMACSLOADPATH now mean the default load-path.
|
||||
|
||||
2013-11-21 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* cmdargs.texi (Action Arguments): Use path-separator with -L.
|
||||
|
||||
2013-11-04 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* cmdargs.texi (Action Arguments): Mention that `-L :...' appends.
|
||||
|
|
|
@ -196,6 +196,7 @@ clean: mostlyclean
|
|||
rm -f emacs-manual-${version}.tar*
|
||||
|
||||
distclean: clean
|
||||
rm -f Makefile
|
||||
|
||||
## In the standalone tarfile, the clean rule runs this.
|
||||
infoclean:
|
||||
|
|
|
@ -598,7 +598,7 @@ convenient to switch between buffers.
|
|||
|
||||
@menu
|
||||
* Uniquify:: Making buffer names unique with directory parts.
|
||||
* Iswitchb:: Switching between buffers with substrings.
|
||||
* Icomplete:: Fast minibuffer selection.
|
||||
* Buffer Menus:: Configurable buffer menu.
|
||||
@end menu
|
||||
|
||||
|
@ -641,39 +641,31 @@ buffer names before you type one. But as an experienced user, if you
|
|||
know the rule, you won't have to look. And then you may find that one
|
||||
rule or another is easier for you to remember and apply quickly.
|
||||
|
||||
@node Iswitchb
|
||||
@subsection Switching Between Buffers using Substrings
|
||||
@node Icomplete
|
||||
@subsection Fast minibuffer selection
|
||||
|
||||
@findex iswitchb-mode
|
||||
@cindex Iswitchb mode
|
||||
@cindex mode, Iswitchb
|
||||
@kindex C-x b @r{(Iswitchb mode)}
|
||||
@kindex C-x 4 b @r{(Iswitchb mode)}
|
||||
@kindex C-x 5 b @r{(Iswitchb mode)}
|
||||
@kindex C-x 4 C-o @r{(Iswitchb mode)}
|
||||
@findex icomplete-mode
|
||||
@cindex Icomplete mode
|
||||
|
||||
Iswitchb global minor mode provides convenient switching between
|
||||
buffers using substrings of their names. It replaces the normal
|
||||
definitions of @kbd{C-x b}, @kbd{C-x 4 b}, @kbd{C-x 5 b}, and @kbd{C-x
|
||||
4 C-o} with alternative commands that are somewhat ``smarter''.
|
||||
Icomplete global minor mode provides a convenient way to quickly select an
|
||||
element among the possible completions in a minibuffer. When enabled, typing
|
||||
in the minibuffer continuously displays a list of possible completions that
|
||||
match the string you have typed.
|
||||
|
||||
When one of these commands prompts you for a buffer name, you can
|
||||
type in just a substring of the name you want to choose. As you enter
|
||||
the substring, Iswitchb mode continuously displays a list of buffers
|
||||
that match the substring you have typed.
|
||||
|
||||
At any time, you can type @key{RET} to select the first buffer in
|
||||
the list. So the way to select a particular buffer is to make it the
|
||||
At any time, you can type @key{C-j} to select the first completion in
|
||||
the list. So the way to select a particular completion is to make it the
|
||||
first in the list. There are two ways to do this. You can type more
|
||||
of the buffer name and thus narrow down the list, excluding unwanted
|
||||
buffers above the desired one. Alternatively, you can use @kbd{C-s}
|
||||
and @kbd{C-r} to rotate the list until the desired buffer is first.
|
||||
of the completion name and thus narrow down the list, excluding unwanted
|
||||
completions above the desired one. Alternatively, you can use @kbd{C-.}
|
||||
and @kbd{C-,} to rotate the list until the desired buffer is first.
|
||||
|
||||
@key{TAB} while entering the buffer name performs completion on the
|
||||
string you have entered, based on the displayed list of buffers.
|
||||
@key{M-TAB} will select the first completion in the list, like @key{C-j} but
|
||||
without exiting the minibuffer, so you can edit it further. This is typically
|
||||
used when entering a file name, where @key{M-TAB} can be used a few times to
|
||||
descend in the hierarchy of directories.
|
||||
|
||||
To enable Iswitchb mode, type @kbd{M-x iswitchb-mode}, or customize
|
||||
the variable @code{iswitchb-mode} to @code{t} (@pxref{Easy
|
||||
To enable Icomplete mode, type @kbd{M-x icomplete-mode}, or customize
|
||||
the variable @code{icomplete-mode} to @code{t} (@pxref{Easy
|
||||
Customization}).
|
||||
|
||||
@node Buffer Menus
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
@cindex switches (command line)
|
||||
@cindex startup (command line arguments)
|
||||
@cindex invocation (command line arguments)
|
||||
@c FIXME: Document `--smid'? --xfq
|
||||
|
||||
Emacs supports command line arguments to request various actions
|
||||
when invoking Emacs. These are for compatibility with other editors
|
||||
|
@ -141,6 +142,8 @@ relative order; i.e., using @samp{-L /foo -L /bar} results in
|
|||
a @code{load-path} of the form @code{("/foo" "/bar" @dots{})}.
|
||||
If @var{dir} begins with @samp{:}, Emacs removes the @samp{:} and
|
||||
appends (rather than prepends) the remainder to @code{load-path}.
|
||||
(On MS Windows, use @samp{;} instead of @samp{:}; i.e., use
|
||||
the value of @code{path-separator}.)
|
||||
|
||||
@item -f @var{function}
|
||||
@opindex -f
|
||||
|
@ -452,13 +455,16 @@ This is used to initialize the variable @code{data-directory}.
|
|||
Directory for the documentation string file, which is used to
|
||||
initialize the Lisp variable @code{doc-directory}.
|
||||
@item EMACSLOADPATH
|
||||
A colon-separated list of directories@footnote{ Here and below,
|
||||
A colon-separated list of directories@footnote{Here and below,
|
||||
whenever we say ``colon-separated list of directories'', it pertains
|
||||
to Unix and GNU/Linux systems. On MS-DOS and MS-Windows, the
|
||||
directories are separated by semi-colons instead, since DOS/Windows
|
||||
file names might include a colon after a drive letter.} to search for
|
||||
Emacs Lisp files. If set, it overrides the usual initial value of the
|
||||
@code{load-path} variable (@pxref{Lisp Libraries}).
|
||||
file names might include a colon after a drive letter.} to search for
|
||||
Emacs Lisp files. If set, it modifies the usual initial value of the
|
||||
@code{load-path} variable (@pxref{Lisp Libraries}). An empty element
|
||||
stands for the default value of @code{load-path}; e.g., using
|
||||
@samp{EMACSLOADPATH="/tmp:"} adds @file{/tmp} to the front of
|
||||
the default @code{load-path}.
|
||||
@item EMACSPATH
|
||||
A colon-separated list of directories to search for executable files.
|
||||
If set, Emacs uses this in addition to @env{PATH} (see below) when
|
||||
|
|
|
@ -115,6 +115,7 @@ display editor. This manual describes how to edit with Emacs and
|
|||
some of the ways to customize it; it corresponds to GNU Emacs version
|
||||
@value{EMACSVER}.
|
||||
|
||||
@c See `manual-html-mono' and `manual-html-node' in admin/admin.el.
|
||||
@ifset WWW_GNU_ORG
|
||||
@html
|
||||
The homepage for GNU Emacs is at
|
||||
|
@ -501,7 +502,7 @@ Using Multiple Buffers
|
|||
Convenience Features and Customization of Buffer Handling
|
||||
|
||||
* Uniquify:: Making buffer names unique with directory parts.
|
||||
* Iswitchb:: Switching between buffers with substrings.
|
||||
* Icomplete:: Fast minibuffer selection.
|
||||
* Buffer Menus:: Configurable buffer menu.
|
||||
|
||||
Multiple Windows
|
||||
|
|
|
@ -2011,8 +2011,8 @@ highlighting (@pxref{Font Lock}). Unlike Enriched mode, Font Lock
|
|||
mode assigns text properties automatically, based on the current
|
||||
buffer contents; those properties are not saved to disk.
|
||||
|
||||
The file @file{etc/enriched.doc} in the Emacs distribution serves as
|
||||
an example of the features of Enriched mode.
|
||||
The file @file{enriched.txt} in Emacs's @code{data-directory}
|
||||
serves as an example of the features of Enriched mode.
|
||||
|
||||
@menu
|
||||
* Enriched Mode:: Entering and exiting Enriched mode.
|
||||
|
|
|
@ -1,3 +1,12 @@
|
|||
2013-12-02 Paul Eggert <eggert@cs.ucla.edu>
|
||||
|
||||
* emacs-lisp-intro.texi (Counting Words): Don't use ':' in xref
|
||||
titles, as this isn't supported by Texinfo.
|
||||
|
||||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* Makefile.in (distclean): Remove Makefile.
|
||||
|
||||
2013-10-23 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* Makefile.in (install-dvi, install-html, install-pdf)
|
||||
|
|
|
@ -113,6 +113,7 @@ clean: mostlyclean
|
|||
rm -f emacs-lispintro-${version}.tar*
|
||||
|
||||
distclean: clean
|
||||
rm -f Makefile
|
||||
|
||||
infoclean:
|
||||
-cd $(buildinfodir) && rm -f eintr$(INFO_EXT) eintr$(INFO_EXT)-[1-9]
|
||||
|
|
|
@ -13544,7 +13544,7 @@ regexps. @xref{the-the, , @code{the-the} Duplicated Words Function}.
|
|||
@end itemize
|
||||
|
||||
@node Counting Words
|
||||
@chapter Counting: Repetition and Regexps
|
||||
@chapter Counting via Repetition and Regexps
|
||||
@cindex Repetition for word counting
|
||||
@cindex Regular expressions for word counting
|
||||
|
||||
|
@ -14428,7 +14428,7 @@ exclamation mark, and question mark. Do the same using recursion.
|
|||
|
||||
Our next project is to count the number of words in a function
|
||||
definition. Clearly, this can be done using some variant of
|
||||
@code{@value{COUNT-WORDS}}. @xref{Counting Words, , Counting Words:
|
||||
@code{@value{COUNT-WORDS}}. @xref{Counting Words, , Counting via
|
||||
Repetition and Regexps}. If we are just going to count the words in
|
||||
one definition, it is easy enough to mark the definition with the
|
||||
@kbd{C-M-h} (@code{mark-defun}) command, and then call
|
||||
|
@ -15602,7 +15602,7 @@ Let's write a function definition to do these tasks. We will use a
|
|||
directory, checking what needs to be done; and we will use a recursive
|
||||
call to repeat the actions on each sub-directory. The recursive
|
||||
pattern is `accumulate'
|
||||
(@pxref{Accumulate, , Recursive Pattern: @emph{accumulate}}),
|
||||
(@pxref{Accumulate}),
|
||||
using @code{append} as the combiner.
|
||||
|
||||
@ignore
|
||||
|
|
|
@ -1,3 +1,60 @@
|
|||
2013-12-04 Juri Linkov <juri@jurta.org>
|
||||
|
||||
* searching.texi (Search and Replace): Fix `unread-command-events'
|
||||
and add ref.
|
||||
|
||||
2013-12-03 Juri Linkov <juri@jurta.org>
|
||||
|
||||
* windows.texi (Choosing Window): Rename `no-display-ok' to
|
||||
`allow-no-window'. (Bug#13594)
|
||||
|
||||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* Makefile.in (distclean): Remove Makefile.
|
||||
|
||||
2013-11-29 Andreas Politz <politza@fh-trier.de>
|
||||
|
||||
* modes.texi (Imenu): Make it clear that sub-alist is the cdr
|
||||
(Bug#14029).
|
||||
|
||||
2013-11-27 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* loading.texi (Library Search):
|
||||
* os.texi (Startup Summary): No more leim directory.
|
||||
|
||||
2013-11-26 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* os.texi (Startup Summary): Update for leim-list being preloaded.
|
||||
|
||||
2013-11-23 Brian Jenkins <brian@brianjenkins.org> (tiny change)
|
||||
|
||||
* frames.texi (Input Focus):
|
||||
* hooks.texi (Standard Hooks): Mention focus-in-hook, focus-out-hook.
|
||||
|
||||
2013-11-23 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* loading.texi (Library Search):
|
||||
Empty elements in EMACSLOADPATH now mean the default load-path.
|
||||
|
||||
2013-11-22 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* loading.texi (Library Search): Minor clarification.
|
||||
|
||||
2013-11-20 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* windows.texi (Choosing Window): Mention `no-display-ok'. (Bug#13594)
|
||||
|
||||
2013-11-19 Xue Fuqiao <xfq.free@gmail.com>
|
||||
|
||||
* os.texi (File Notifications): Add an index.
|
||||
|
||||
* loading.texi (Loading): Add an cross-reference.
|
||||
|
||||
2013-11-18 Xue Fuqiao <xfq.free@gmail.com>
|
||||
|
||||
* os.texi (Session Management, Desktop Notifications): Add some
|
||||
indexes and a cross-reference.
|
||||
|
||||
2013-11-17 Xue Fuqiao <xfq.free@gmail.com>
|
||||
|
||||
* os.texi (Time Parsing):
|
||||
|
|
|
@ -169,6 +169,7 @@ clean: mostlyclean
|
|||
rm -f emacs-lispref-${version}.tar*
|
||||
|
||||
distclean: clean
|
||||
rm -f Makefile
|
||||
|
||||
infoclean:
|
||||
-cd $(buildinfodir) && rm -f elisp$(INFO_EXT) elisp$(INFO_EXT)-[1-9] elisp$(INFO_EXT)-[1-9][0-9]
|
||||
|
|
|
@ -1479,6 +1479,14 @@ The redirection lasts until @code{redirect-frame-focus} is called to
|
|||
change it.
|
||||
@end defun
|
||||
|
||||
@defvar focus-in-hook
|
||||
This is a normal hook run when an Emacs frame gains input focus.
|
||||
@end defvar
|
||||
|
||||
@defvar focus-out-hook
|
||||
This is a normal hook run when an Emacs frame loses input focus.
|
||||
@end defvar
|
||||
|
||||
@defopt focus-follows-mouse
|
||||
This option is how you inform Emacs whether the window manager transfers
|
||||
focus when the user moves the mouse. Non-@code{nil} says that it does.
|
||||
|
|
|
@ -115,6 +115,12 @@ Function to call to ``quit'' the current buffer.
|
|||
@vindex delayed-warnings-hook
|
||||
The command loop runs this soon after @code{post-command-hook} (q.v.).
|
||||
|
||||
@item focus-in-hook
|
||||
@vindex focus-in-hook
|
||||
@itemx focus-out-hook
|
||||
@vindex focus-out-hook
|
||||
@xref{Input Focus}.
|
||||
|
||||
@item delete-frame-functions
|
||||
@xref{Deleting Frames}.
|
||||
|
||||
|
|
|
@ -29,6 +29,8 @@ into a buffer and evaluated there. (Indeed, most code is tested this
|
|||
way.) Most often, the forms are function definitions and variable
|
||||
definitions.
|
||||
|
||||
For on-demand loading of external libraries, @pxref{Dynamic Libraries}.
|
||||
|
||||
@menu
|
||||
* How Programs Do Loading:: The @code{load} function and others.
|
||||
* Load Suffixes:: Details about the suffixes that @code{load} tries.
|
||||
|
@ -268,16 +270,19 @@ is a directory something like
|
|||
"/usr/local/share/emacs/@var{version}/lisp"
|
||||
@end example
|
||||
|
||||
followed by a similarly named @file{leim} directory. These
|
||||
directories contain the standard Lisp files that come with Emacs.
|
||||
If Emacs cannot find them, it will not start correctly.
|
||||
(In this and the following examples, replace @file{/usr/local} with
|
||||
the installation prefix appropriate for your Emacs.)
|
||||
These directories contain the standard Lisp files that come with
|
||||
Emacs. If Emacs cannot find them, it will not start correctly.
|
||||
|
||||
If you run Emacs from the directory where it was built---that is, an
|
||||
executable that has not been formally installed---Emacs instead
|
||||
initializes @code{load-path} using the @file{lisp} and @file{leim}
|
||||
directories in the directory containing the sources from which it
|
||||
was built. If you built Emacs in a separate directory from the
|
||||
sources, it also adds those directories from the build directory.
|
||||
initializes @code{load-path} using the @file{lisp}
|
||||
directory in the directory containing the sources from which it
|
||||
was built.
|
||||
@c Though there should be no *.el files in builddir/lisp, so it's pointless.
|
||||
If you built Emacs in a separate directory from the
|
||||
sources, it also adds the lisp directories from the build directory.
|
||||
(In all cases, elements are represented as absolute file names.)
|
||||
|
||||
@cindex site-lisp directories
|
||||
|
@ -306,25 +311,34 @@ directories, if they exist. Normally these directories do not contain
|
|||
@file{site-lisp} directories.)
|
||||
|
||||
@cindex @env{EMACSLOADPATH} environment variable
|
||||
If the environment variable @env{EMACSLOADPATH} is set, it overrides
|
||||
the above initialization procedure. That is, Emacs initializes
|
||||
@code{load-path} based solely on the value of the environment
|
||||
variable. You must therefore include the directory containing the
|
||||
standard Lisp files, else Emacs will not function. In most
|
||||
situations, it is better to use the @option{-L} command-line option
|
||||
(see below) to add elements to @code{load-path}.
|
||||
If the environment variable @env{EMACSLOADPATH} is set, it modifies
|
||||
the above initialization procedure. Emacs initializes
|
||||
@code{load-path} based on the value of the environment variable.
|
||||
|
||||
The syntax of @env{EMACSLOADPATH} is the same as used for @code{PATH};
|
||||
directory names are separated by @samp{:} (or @samp{;}, on some
|
||||
operating systems), and @samp{.} stands for the current default
|
||||
directory. Here is an example of how to set @env{EMACSLOADPATH}
|
||||
variable (from a @command{sh}-style shell):
|
||||
operating systems).
|
||||
@ignore
|
||||
@c AFAICS, does not (yet) work right to specify non-absolute elements.
|
||||
and @samp{.} stands for the current default directory.
|
||||
@end ignore
|
||||
Here is an example of how to set @env{EMACSLOADPATH} variable (from a
|
||||
@command{sh}-style shell):
|
||||
|
||||
@example
|
||||
export EMACSLOADPATH
|
||||
EMACSLOADPATH=/home/foo/.emacs.d/lisp:/usr/local/emacs/24.3/lisp
|
||||
export EMACSLOADPATH=/home/foo/.emacs.d/lisp:
|
||||
@end example
|
||||
|
||||
An empty element in the value of the environment variable, whether
|
||||
trailing (as in the above example), leading, or embedded, is replaced
|
||||
by the default value of @code{load-path} as determined by the standard
|
||||
initialization procedure. If there are no such empty elements, then
|
||||
@env{EMACSLOADPATH} specifies the entire @code{load-path}. You must
|
||||
include either an empty element, or the explicit path to the directory
|
||||
containing the standard Lisp files, else Emacs will not function.
|
||||
(Another way to modify @code{load-path} is to use the @option{-L}
|
||||
command-line option when starting Emacs; see below.)
|
||||
|
||||
For each directory in @code{load-path}, Emacs then checks to see if
|
||||
it contains a file @file{subdirs.el}, and if so, loads it. The
|
||||
@file{subdirs.el} file is created when Emacs is built/installed,
|
||||
|
|
|
@ -2483,7 +2483,7 @@ Selecting a special element performs:
|
|||
A nested sub-alist element looks like this:
|
||||
|
||||
@example
|
||||
(@var{menu-title} @var{sub-alist})
|
||||
(@var{menu-title} . @var{sub-alist})
|
||||
@end example
|
||||
|
||||
It creates the submenu @var{menu-title} specified by @var{sub-alist}.
|
||||
|
|
|
@ -71,11 +71,12 @@ in their turn. The files @file{subdirs.el} are normally generated
|
|||
automatically when Emacs is installed.
|
||||
|
||||
@item
|
||||
If the library @file{leim-list.el} exists, Emacs loads it. This
|
||||
optional library is intended for registering input methods; Emacs
|
||||
looks for it in @code{load-path} (@pxref{Library Search}), skipping
|
||||
those directories containing the standard Emacs libraries (since
|
||||
@file{leim-list.el} should not exist in those directories).
|
||||
It loads any @file{leim-list.el} that it finds in the @code{load-path}
|
||||
directories. This file is intended for registering input methods.
|
||||
The search is only for any personal @file{leim-list.el} files that you
|
||||
may have created; it skips the directories containing the standard Emacs
|
||||
libraries (these should contain only a single @file{leim-list.el} file,
|
||||
which is compiled into the Emacs executable).
|
||||
|
||||
@vindex before-init-time
|
||||
@item
|
||||
|
@ -2244,6 +2245,7 @@ saved session to restore. For Emacs, this argument is @samp{--smid
|
|||
@var{session}}.
|
||||
|
||||
@defvar emacs-save-session-functions
|
||||
@cindex session file
|
||||
Emacs supports saving state via a hook called
|
||||
@code{emacs-save-session-functions}. Emacs runs this hook when the
|
||||
session manager tells it that the window system is shutting down. The
|
||||
|
@ -2283,11 +2285,13 @@ Emacs is restarted by the session manager.
|
|||
@node Desktop Notifications
|
||||
@section Desktop Notifications
|
||||
@cindex desktop notifications
|
||||
@cindex notifications, on desktop
|
||||
|
||||
Emacs is able to send @dfn{notifications} on systems that support the
|
||||
freedesktop.org Desktop Notifications Specification. In order to use
|
||||
this functionality, Emacs must have been compiled with D-Bus support,
|
||||
and the @code{notifications} library must be loaded.
|
||||
and the @code{notifications} library must be loaded. @xref{Top, ,
|
||||
D-Bus,dbus,D-Bus integration in Emacs}.
|
||||
|
||||
@defun notifications-notify &rest params
|
||||
This function sends a notification to the desktop via D-Bus,
|
||||
|
@ -2523,6 +2527,7 @@ specification prior to @samp{"1.0"}.
|
|||
@node File Notifications
|
||||
@section Notifications on File Changes
|
||||
@cindex file notifications
|
||||
@cindex watch, for filesystem events
|
||||
|
||||
Several operating systems support watching of filesystems for changes
|
||||
of files. If configured properly, Emacs links a respective library
|
||||
|
|
|
@ -1770,10 +1770,9 @@ Do not take action for this question---in other words, ``no''.
|
|||
Answer this question ``no'', and give up on the entire series of
|
||||
questions, assuming that the answers will be ``no''.
|
||||
|
||||
@c FIXME: Document ‘unread-comment-events’? --xfq
|
||||
@item exit-prefix
|
||||
Like @code{exit}, but add the key that was pressed to
|
||||
@code{unread-comment-events}.
|
||||
@code{unread-command-events} (@pxref{Event Input Misc}).
|
||||
|
||||
@item act-and-exit
|
||||
Answer this question ``yes'', and give up on the entire series of
|
||||
|
|
|
@ -1842,7 +1842,10 @@ The constant @code{display-buffer-fallback-action}.
|
|||
@noindent
|
||||
Each action function is called in turn, passing the buffer as the
|
||||
first argument and the combined action alist as the second argument,
|
||||
until one of the functions returns non-@code{nil}.
|
||||
until one of the functions returns non-@code{nil}. The caller can
|
||||
pass @code{(allow-no-window . t)} as an element of the action alist to
|
||||
indicate its readiness to handle the case of not displaying the
|
||||
buffer in a window.
|
||||
|
||||
The argument @var{action} can also have a non-@code{nil}, non-list
|
||||
value. This has the special meaning that the buffer should be
|
||||
|
|
|
@ -1,3 +1,30 @@
|
|||
2013-12-06 Bastien Guerry <bzg@gnu.org>
|
||||
|
||||
* org.texi: Don't include Emacs version within Org's version.
|
||||
|
||||
2013-12-06 Nicolas Goaziou <n.goaziou@gmail.com>
|
||||
|
||||
* org.texi (Creating one-off styles): Use new export snippet
|
||||
syntax.
|
||||
|
||||
* org.texi (Export settings): documentation describing how text
|
||||
above the first heading is ignored when an :export: tag is in a
|
||||
file.
|
||||
|
||||
2013-12-05 Michael Albinus <michael.albinus@gmx.de>
|
||||
|
||||
* dbus.texi (Type Conversion): Clarify unibyte-ness of strings.
|
||||
|
||||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* Makefile.in (distclean): Remove Makefile.
|
||||
|
||||
2013-11-20 era eriksson <era+emacsbugs@iki.fi>
|
||||
|
||||
* ses.texi (Quick Tutorial): New chapter. (Bug#14748)
|
||||
(The Basics, Formulas): Copyedits.
|
||||
(Resizing, Printer functions): Add index entries.
|
||||
|
||||
2013-11-17 Jay Belanger <jay.p.belanger@gmail.com>
|
||||
|
||||
* calc.texi (Customizing Calc): Mention new variable
|
||||
|
|
|
@ -842,7 +842,7 @@ clean: mostlyclean
|
|||
rm -f emacs-misc-${version}.tar*
|
||||
|
||||
distclean: clean
|
||||
# rm -f Makefile
|
||||
rm -f Makefile
|
||||
|
||||
## buildinfodir is relative to srcdir.
|
||||
infoclean:
|
||||
|
|
|
@ -1138,10 +1138,11 @@ The signal @code{PropertyModified}, discussed as example in
|
|||
(@var{INTEGER} ((@var{STRING} @var{BOOL} @var{BOOL}) (@var{STRING} @var{BOOL} @var{BOOL}) @dots{}))
|
||||
@end lisp
|
||||
|
||||
@defun dbus-byte-array-to-string byte-array
|
||||
@defun dbus-byte-array-to-string byte-array &optional multibyte
|
||||
If a D-Bus method or signal returns an array of bytes, which are known
|
||||
to represent an UTF8 string, this function converts @var{byte-array}
|
||||
to the corresponding string. Example:
|
||||
to the corresponding string. The string is unibyte encoded, unless
|
||||
@var{multibyte} is non-@code{nil}. Example:
|
||||
|
||||
@lisp
|
||||
(dbus-byte-array-to-string '(47 101 116 99 47 104 111 115 116 115))
|
||||
|
@ -1151,20 +1152,30 @@ to the corresponding string. Example:
|
|||
@end defun
|
||||
|
||||
@defun dbus-unescape-from-identifier string
|
||||
Retrieve the original string from the encoded @var{string}.
|
||||
@var{string} must have been coded with
|
||||
Retrieve the original string from the encoded @var{string} as unibyte
|
||||
string. @var{string} must have been encoded with
|
||||
@code{dbus-escape-as-identifier}. Example:
|
||||
|
||||
@lisp
|
||||
(dbus-unescape-from-identifier "_30123abc_5fxyz_01_ff")
|
||||
|
||||
@ifinfo
|
||||
@result{} "0123abc_xyz^Aÿ"
|
||||
@end ifinfo
|
||||
@ifnotinfo
|
||||
@result{} "0123abc_xyz^A@"y"
|
||||
@end ifnotinfo
|
||||
@result{} "0123abc_xyz\x01\xff"
|
||||
@end lisp
|
||||
|
||||
If the original string used in @code{dbus-escape-as-identifier} is a
|
||||
multibyte string, it cannot be expected that this function returns
|
||||
that string:
|
||||
|
||||
@lisp
|
||||
(string-equal
|
||||
(dbus-unescape-from-identifier
|
||||
(dbus-escape-as-identifier "Grüß Göttin"))
|
||||
"Grüß Göttin")
|
||||
|
||||
@result{} nil
|
||||
@end lisp
|
||||
|
||||
|
||||
@end defun
|
||||
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
@c %**start of header
|
||||
@setfilename ../../info/org
|
||||
@settitle The Org Manual
|
||||
@set VERSION 8.2.3 (GNU Emacs 24.3)
|
||||
@set VERSION 8.2.4
|
||||
|
||||
@c Use proper quote and backtick for code sections in PDF output
|
||||
@c Cf. Texinfo manual 14.2
|
||||
|
@ -10518,7 +10518,8 @@ clocktable.
|
|||
The tags that select a tree for export (@code{org-export-select-tags}). The
|
||||
default value is @code{:export:}. Within a subtree tagged with
|
||||
@code{:export:}, you can still exclude entries with @code{:noexport:} (see
|
||||
below).
|
||||
below). When headlines are selectively exported with @code{:export:}
|
||||
anywhere in a file, text before the first headline is ignored.
|
||||
|
||||
@item EXCLUDE_TAGS
|
||||
The tags that exclude a tree from export (@code{org-export-exclude-tags}).
|
||||
|
@ -12542,13 +12543,13 @@ file. The use of this feature is better illustrated with couple of examples.
|
|||
@enumerate
|
||||
@item Embedding ODT tags as part of regular text
|
||||
|
||||
You can include simple OpenDocument tags by prefixing them with
|
||||
@samp{@@}. For example, to highlight a region of text do the following:
|
||||
You can inline OpenDocument syntax by enclosing it within
|
||||
@samp{@@@@odt:...@@@@} markup. For example, to highlight a region of text do
|
||||
the following:
|
||||
|
||||
@example
|
||||
@@<text:span text:style-name="Highlight">This is a
|
||||
highlighted text@@</text:span>. But this is a
|
||||
regular text.
|
||||
@@@@odt:<text:span text:style-name="Highlight">This is a highlighted
|
||||
text</text:span>@@@@. But this is a regular text.
|
||||
@end example
|
||||
|
||||
@strong{Hint:} To see the above example in action, edit your
|
||||
|
|
|
@ -66,6 +66,7 @@ To report bugs, use @kbd{M-x report-emacs-bug}.
|
|||
|
||||
@menu
|
||||
* Sales Pitch:: Why use @acronym{SES}?
|
||||
* Quick Tutorial:: A quick introduction
|
||||
* The Basics:: Basic spreadsheet commands
|
||||
* Advanced Features:: Want to know more?
|
||||
* For Gurus:: Want to know @emph{even more}?
|
||||
|
@ -98,6 +99,95 @@ To report bugs, use @kbd{M-x report-emacs-bug}.
|
|||
|
||||
@c ===================================================================
|
||||
|
||||
@node Quick Tutorial
|
||||
@chapter Quick Tutorial
|
||||
@cindex introduction
|
||||
@cindex tutorial
|
||||
|
||||
If you want to get started quickly and think that you know what to
|
||||
expect from a simple spreadsheet, this chapter may be all that you
|
||||
need.
|
||||
|
||||
First, visit a new file with the @file{.ses} extension.
|
||||
Emacs presents you with an empty spreadsheet containing a single cell.
|
||||
|
||||
Begin by inserting a headline: @kbd{"Income"@key{RET}}. The double
|
||||
quotes indicate that this is a text cell. (Notice that Emacs
|
||||
automatically inserts the closing quotation mark.)
|
||||
|
||||
To insert your first income value, you must first resize the
|
||||
spreadsheet. Press @key{TAB} to add a new cell and navigate back up
|
||||
to it. Enter a number, such as @samp{2.23}. Then proceed to add a
|
||||
few more income entries, e.g.:
|
||||
|
||||
@example
|
||||
@group
|
||||
A
|
||||
Income
|
||||
2.23
|
||||
0.02
|
||||
15.76
|
||||
-4.00
|
||||
@end group
|
||||
@end example
|
||||
|
||||
To add up the values, enter a Lisp expression:
|
||||
|
||||
@example
|
||||
(+ A2 A3 A4 A5)
|
||||
@end example
|
||||
|
||||
Perhaps you want to add a cell to the right of cell A4 to explain
|
||||
why you have a negative entry. Pressing @kbd{TAB} in that cell
|
||||
adds an entire new column @samp{B}, where you can add such a note.
|
||||
|
||||
The column is fairly narrow by default, but pressing @kbd{w} allows
|
||||
you to resize it as needed. Make it 20 characters wide. You can
|
||||
now add descriptive legends for all the entries, e.g.:
|
||||
|
||||
@example
|
||||
@group
|
||||
A B
|
||||
Income
|
||||
2.23 Consulting fee
|
||||
0.02 Informed opinion
|
||||
15.76 Lemonade stand
|
||||
-4 Loan to Joe
|
||||
14.01 Total
|
||||
@end group
|
||||
@end example
|
||||
|
||||
By default, the labels in column B are right-justified. To change
|
||||
that, you can enter a printer function for the whole column, using
|
||||
e.g., @kbd{M-p ("%s")}. You can override a column's printer function
|
||||
in any individual cell using @kbd{p}.
|
||||
|
||||
If Joe pays back his loan, you might blank that entry; e.g., by
|
||||
positioning the cursor in cell A5 and pressing @kbd{C-d} twice.
|
||||
If you do that, the total cell will display @samp{######}. That is
|
||||
because the regular @code{+} operator does not handle a range that
|
||||
contains some empty cells. Instead of emptying the cell, you could
|
||||
enter a literal @samp{0}, or delete the entire row using @kbd{C-k}.
|
||||
An alternative is to use the special function @code{ses+} instead of
|
||||
the regular @code{+}:
|
||||
|
||||
@example
|
||||
(ses+ A2 A3 A4 A5)
|
||||
@end example
|
||||
|
||||
To make a formula robust against changes in the spreadsheet geometry,
|
||||
you can use the @code{ses-range} macro to refer to a range of cells by
|
||||
the end-points, e.g.:
|
||||
|
||||
@example
|
||||
(apply 'ses+ (ses-range A2 A5))
|
||||
@end example
|
||||
|
||||
(The @code{apply} is necessary because @code{ses-range} produces a
|
||||
@emph{list} of values. This allows for more complex possibilities.)
|
||||
|
||||
@c ===================================================================
|
||||
|
||||
@node The Basics
|
||||
@comment node-name, next, previous, up
|
||||
@chapter The Basics
|
||||
|
@ -117,6 +207,7 @@ A @dfn{cell identifier} is a symbol with a column letter and a row
|
|||
number. Cell B7 is the 2nd column of the 7th row. For very wide
|
||||
spreadsheets, there are two column letters: cell AB7 is the 28th
|
||||
column of the 7th row. Super wide spreadsheets get AAA1, etc.
|
||||
You move around with the regular Emacs movement commands.
|
||||
|
||||
@table @kbd
|
||||
@item j
|
||||
|
@ -161,13 +252,17 @@ Highlight all cells (@code{mark-whole-buffer}).
|
|||
@section Cell formulas
|
||||
@cindex formulas
|
||||
@cindex formulas, entering
|
||||
@cindex values
|
||||
@cindex cell values
|
||||
@cindex editing cells
|
||||
@findex ses-read-cell
|
||||
@findex ses-read-symbol
|
||||
@findex ses-edit-cell
|
||||
@findex ses-recalculate-cell
|
||||
@findex ses-recalculate-all
|
||||
|
||||
To enter a number into the current cell, just start typing:
|
||||
To insert a value into a cell, simply type a numeric expression,
|
||||
@samp{"double-quoted text"}, or a Lisp expression.
|
||||
|
||||
@table @kbd
|
||||
@item 0..9
|
||||
|
@ -213,6 +308,13 @@ Recalculate the entire spreadsheet (@code{ses-recalculate-all}).
|
|||
@node Resizing
|
||||
@section Resizing the spreadsheet
|
||||
@cindex resizing spreadsheets
|
||||
@cindex dimensions
|
||||
@cindex row, adding or removing
|
||||
@cindex column, adding or removing
|
||||
@cindex adding rows or columns
|
||||
@cindex inserting rows or columns
|
||||
@cindex removing rows or columns
|
||||
@cindex deleting rows or columns
|
||||
@findex ses-insert-row
|
||||
@findex ses-insert-column
|
||||
@findex ses-delete-row
|
||||
|
@ -269,6 +371,8 @@ Undo previous action (@code{(undo)}).
|
|||
@node Printer functions
|
||||
@section Printer functions
|
||||
@cindex printer functions
|
||||
@cindex cell formatting
|
||||
@cindex formatting cells
|
||||
@findex ses-read-cell-printer
|
||||
@findex ses-read-column-printer
|
||||
@findex ses-read-default-printer
|
||||
|
|
|
@ -1,3 +1,17 @@
|
|||
2013-11-23 Xue Fuqiao <xfq.free@gmail.com>
|
||||
|
||||
* TODO: Minor update.
|
||||
|
||||
2013-11-23 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* enriched.txt: Rename from enriched.doc. (Bug#15947)
|
||||
Misc small updates for this hardly being "new" any more.
|
||||
|
||||
2013-11-20 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* NEWS: Mention new display action alist entry `no-display-ok'.
|
||||
(Bug#13594)
|
||||
|
||||
2013-11-18 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* NEWS: Mention new features for Octave mode.
|
||||
|
|
65
etc/NEWS
65
etc/NEWS
|
@ -62,9 +62,20 @@ To use the old backend by default, do on the command line:
|
|||
|
||||
* Startup Changes in Emacs 24.4
|
||||
|
||||
+++
|
||||
** When initializing `load-path', an empty element in the EMACSLOADPATH
|
||||
environment variable (either leading, e.g., ":/foo"; trailing, e.g.,
|
||||
"/foo:"; or embedded, e.g., "/foo::/bar") is replaced with the default
|
||||
load-path (the one that would have been used if EMACSLOADPATH was unset).
|
||||
This makes it easier to _extend_ the load-path via EMACSLOADPATH
|
||||
(previously, EMACSLOADPATH had to specify the complete load-path,
|
||||
including the defaults). (In older versions of Emacs, an empty element
|
||||
was replaced by ".", so use an explicit "." now if that is what you want.)
|
||||
|
||||
+++
|
||||
** The -L option, which normally prepends its argument to load-path,
|
||||
will instead append, if the argument begins with `:'.
|
||||
will instead append, if the argument begins with `:' (or `;' on MS Windows;
|
||||
i.e., `path-separator').
|
||||
|
||||
|
||||
* Changes in Emacs 24.4
|
||||
|
@ -160,10 +171,13 @@ monitor, use the new functions above. Similar notes also apply to
|
|||
`x-display-pixel-width', `x-display-pixel-height', `display-mm-width',
|
||||
`display-mm-height', `x-display-mm-width', and `x-display-mm-height'.
|
||||
|
||||
** New macro `alternatives-define' can be used to define generic commands.
|
||||
** New macro `define-alternatives' can be used to define generic commands.
|
||||
Generic commands are interactive functions whose implementation can be
|
||||
selected among several alternatives, as a matter of user preference.
|
||||
|
||||
** New hooks `focus-in-hook', `focus-out-hook'.
|
||||
These are normal hooks run when an Emacs frame gains or loses input focus.
|
||||
|
||||
** The blink cursor stops blinking after 10 blinks (default) on X and NS.
|
||||
You can change the default by customizing the variable blink-cursor-blinks.
|
||||
Also timers for blinking are stopped when no blinking is done, so Emacs does
|
||||
|
@ -189,6 +203,10 @@ Czech typography rules. To globally enable this feature, evaluate:
|
|||
|
||||
* Editing Changes in Emacs 24.4
|
||||
|
||||
** `electric-indent-mode' is enabled by default.
|
||||
|
||||
** Uniquify is enabled by default.
|
||||
|
||||
** Command `rectangle-mark-mode' bound to C-x SPC makes a rectangular region.
|
||||
Most commands are still unaware of it, but kill/yank do work on the rectangle.
|
||||
|
||||
|
@ -229,6 +247,8 @@ You can pick the name of the function and the variables with `C-x 4 a'.
|
|||
|
||||
* Changes in Specialized Modes and Packages in Emacs 24.4
|
||||
|
||||
** The backtrace debugger can display local vars with `v'.
|
||||
|
||||
** prolog-use-smie has been removed, along with the non-SMIE indentation code.
|
||||
|
||||
** SMIE indentation can be customized via `smie-config'.
|
||||
|
@ -625,6 +645,22 @@ whether it is safe to use Bash's --noediting option. These days
|
|||
+++
|
||||
** There is a new macro `skip-unless' for skipping ERT tests. See the manual.
|
||||
|
||||
** Imenu
|
||||
|
||||
*** New option `imenu-generic-skip-comments-and-strings'.
|
||||
|
||||
** Ruby mode
|
||||
|
||||
*** New option `ruby-encoding-magic-comment-style'.
|
||||
|
||||
*** New option `ruby-custom-encoding-magic-comment-template'.
|
||||
|
||||
*** New mode menu.
|
||||
|
||||
*** Improved syntax highlighting and indentation.
|
||||
|
||||
*** Add more Ruby file types to `auto-mode-alist'.
|
||||
|
||||
|
||||
* New Modes and Packages in Emacs 24.4
|
||||
|
||||
|
@ -717,6 +753,8 @@ for something (not just adding elements to it), it ought not to affect you.
|
|||
|
||||
* Lisp Changes in Emacs 24.4
|
||||
|
||||
** New function get-pos-property.
|
||||
|
||||
** New hook `pre-redisplay-function'.
|
||||
|
||||
+++
|
||||
|
@ -736,8 +774,8 @@ frame.
|
|||
*** `bool-vector-set-difference'
|
||||
*** `bool-vector-not'
|
||||
*** `bool-vector-subsetp'
|
||||
*** `bool-vector-count-matches'
|
||||
*** `bool-vector-count-matches-at'
|
||||
*** `bool-vector-count-consecutive'
|
||||
*** `bool-vector-count-population'
|
||||
|
||||
** Comparison functions =, <, >, <=, >= now take many arguments.
|
||||
|
||||
|
@ -755,6 +793,13 @@ frame.
|
|||
** New library helpers.el for misc helper functions
|
||||
*** `hash-table-keys'
|
||||
*** `hash-table-values'
|
||||
*** `string-blank-p`
|
||||
*** `string-empty-p`
|
||||
*** `string-join`
|
||||
*** `string-reverse`
|
||||
*** `string-trim-left'
|
||||
*** `string-trim-right'
|
||||
*** `string-trim'
|
||||
|
||||
** Obsoleted functions:
|
||||
*** `log10'
|
||||
|
@ -772,10 +817,15 @@ The few hooks that used with-wrapper-hook are replaced as follows:
|
|||
*** `completion-in-region-function' obsoletes `completion-in-region-functions'.
|
||||
*** `filter-buffer-substring-function' obsoletes `filter-buffer-substring-functions'.
|
||||
|
||||
** `byte-compile-interactive-only-functions' is now obsolete.
|
||||
It has been replaced by the symbol property 'interactive-only.
|
||||
|
||||
** `split-string' now takes an optional argument TRIM.
|
||||
The value, if non-nil, is a regexp that specifies what to trim from
|
||||
the start and end of each substring.
|
||||
|
||||
** New function `string-suffix-p'.
|
||||
|
||||
** `get-upcase-table' is obsoleted by the new `case-table-get-table'.
|
||||
|
||||
** Support for filesystem notifications.
|
||||
|
@ -1806,6 +1856,13 @@ reused.
|
|||
*** New option `switch-to-buffer-preserve-window-point' to restore a
|
||||
window's point when switching buffers.
|
||||
|
||||
*** New display action function `display-buffer-no-window' to not
|
||||
display the buffer in a window.
|
||||
|
||||
*** New display action alist entry `allow-no-window' to indicate the
|
||||
caller of `display-buffer' is ready to handle the case of not
|
||||
displaying the buffer in a window.
|
||||
|
||||
*** New display action alist entries `window-height' and `window-width'
|
||||
specify the size of new windows created by `display-buffer'.
|
||||
|
||||
|
|
8
etc/TODO
8
etc/TODO
|
@ -203,7 +203,7 @@ http://lists.gnu.org/archive/html/emacs-devel/2008-08/msg00456.html
|
|||
** "Emacs as word processor"
|
||||
http://lists.gnu.org/archive/html/emacs-devel/2013-11/msg00515.html
|
||||
rms writes:
|
||||
25 years ago I hoped we would extend Emacs to do WYSIWG word
|
||||
25 years ago I hoped we would extend Emacs to do WYSIWYG word
|
||||
processing. That is why we added text properties and variable
|
||||
width fonts. However, more features are still needed to achieve this.
|
||||
|
||||
|
@ -544,8 +544,8 @@ rather than interactively. This a trivial one-liner in easy-mode.el.
|
|||
aim for completeness, but some may be worth documenting.
|
||||
|
||||
Here's a list which is probably not complete/correct: align, allout,
|
||||
artist, ansi-color, array, battery, calculator, cdl, cmuscheme,
|
||||
completion, cua, delim-col, dirtrack, double, echistory, elide-head,
|
||||
artist, ansi-color, array, calculator, cdl, cmuscheme,
|
||||
completion, delim-col, dirtrack, double, echistory, elide-head,
|
||||
easymenu, expand, flow-ctrl, format [format-alist],
|
||||
generic/generic-x [various modes], kermit, log-edit,
|
||||
makesum, midnight [other than in Kill Buffer node],
|
||||
|
@ -554,7 +554,7 @@ rather than interactively. This a trivial one-liner in easy-mode.el.
|
|||
the web page], talk, thingatpt [interactive functions?], type-break,
|
||||
vcursor, xscheme, zone-mode [?], mlconvert [?], iso-cvt,
|
||||
feedmail [?], uce, gametree, meese, page-ext,
|
||||
refbib, refer, scribe, sgml-mode, spell, texinfo, underline,
|
||||
refbib, refer, scribe, spell [obsolete?], texinfo, underline,
|
||||
cmacexp, hideif, mantemp [obsolete?], pcomplete, xml,
|
||||
cvs-status (should be described in PCL-CVS manual); other progmodes,
|
||||
probably in separate manual.
|
||||
|
|
|
@ -10,10 +10,10 @@ Text-Width: 70
|
|||
|
||||
|
||||
|
||||
<indent>Emacs now has the ability to edit <italic>enriched text</italic>, which is text
|
||||
containing faces, colors, indentation, and other properties. This
|
||||
document is a quick introduction to some of the new features, and
|
||||
is also an example file in the <italic>text/enriched </italic>format.</indent>
|
||||
<indent>Emacs has the ability to edit <italic>enriched text</italic>, which is text
|
||||
containing faces, colors, indentation, and other properties.
|
||||
This document is a quick introduction to some of the features,
|
||||
and is also an example file in the <italic>text/enriched </italic>format.</indent>
|
||||
|
||||
|
||||
<x-bg-color><param>blue</param><x-color><param>white</param><bold>INSTALLATION and STARTUP</bold></x-color></x-bg-color>
|
||||
|
@ -71,7 +71,7 @@ the right margin, fully justified, centered, or left alone).</indent>
|
|||
<x-bg-color><param>blue</param><x-color><param>white</param><bold>FACES and COLORS</bold></x-color></x-bg-color>
|
||||
|
||||
|
||||
<indent>You can add faces either with the menu or with <fixed>M-g.</fixed> The face is
|
||||
<indent>You can add faces either with the menu or with <fixed>M-o.</fixed> The face is
|
||||
applied to the current region. If you are using
|
||||
`transient-mark-mode' and the region is not active, then the face
|
||||
applies to whatever you type next. Any face can have colors. If
|
||||
|
@ -175,16 +175,8 @@ all of the features of your document, but they will get as close
|
|||
as possible.
|
||||
|
||||
|
||||
The MIME standard is defined in </indent>Internet<indent> RFC 1521; text/enriched
|
||||
is defined in RFC 1563. Details on obtaining these documents via
|
||||
FTP or email may be obtained by sending an email message to
|
||||
<fixed>rfc-info@isi.edu</fixed> with the message body:
|
||||
|
||||
|
||||
<fixed><indent>help: ways_to_get_rfcs</indent></fixed>
|
||||
|
||||
|
||||
<indent>See also the newsgroup <fixed>comp.mail.mime</fixed>.</indent></indent>
|
||||
The text/enriched standard is defined in </indent>Internet<indent> RFC 1896
|
||||
(<<http://www.ietf.org/rfc/rfc1896.txt>).</indent></indent>
|
||||
|
||||
|
||||
<x-bg-color><param>blue</param><x-color><param>white</param><bold>CUSTOMIZATION</bold></x-color></x-bg-color><bold>
|
||||
|
@ -198,16 +190,15 @@ enriched-verbose.
|
|||
</fixed></indent>-<indent> You can add annotations for your own text properties by making
|
||||
additions to <fixed>enriched-translations</fixed>. Note that the standard
|
||||
requires you to name your annotation starting<italic> "x-" </italic>(as in
|
||||
<italic>"x-read-only"</italic>). Please send me any such additions that you
|
||||
think might be of general interest so that I can include them
|
||||
in the distribution.</indent>
|
||||
<italic>"x-read-only"</italic>). Please report any such additions that you
|
||||
think might be of general interest using <fixed>M-x report-emacs-bug</fixed>.</indent>
|
||||
|
||||
</indent>
|
||||
|
||||
<x-bg-color><param>blue</param><x-color><param>white</param><bold>TO-DO LIST</bold></x-color></x-bg-color>
|
||||
<x-bg-color><param>blue</param><x-color><param>white</param><bold>TODO LIST</bold></x-color></x-bg-color>
|
||||
|
||||
|
||||
<italic><indent>[Feel free to work on these and send me the results!]</indent></italic><indent>
|
||||
<italic><indent>[Feel free to work on these and send us the results!]</indent></italic><indent>
|
||||
|
||||
+ Conform to updated text/enriched spec in RFC 1896.
|
||||
|
||||
|
@ -238,22 +229,15 @@ it.</indent>
|
|||
|
||||
+ Support more formats: RTF, HTML...
|
||||
|
||||
+ Use Emacs 21 display features.
|
||||
+ Use modern Emacs display features.
|
||||
|
||||
</indent>
|
||||
|
||||
<x-bg-color><param>blue</param><x-color><param>white</param><bold>Final Notes:</bold></x-color></x-bg-color>
|
||||
|
||||
|
||||
<indent>This code and documentation is under development. Comments and
|
||||
bug reports are welcome.</indent>
|
||||
<x-bg-color><param>blue</param><x-color><param>white</param><bold>Original Author:</bold></x-color></x-bg-color>
|
||||
|
||||
|
||||
<bold><x-color><param>white</param><x-bg-color><param>blue</param>Boris Goldowsky</x-bg-color></x-color><x-color><param>light blue</param> </x-color></bold><x-color><param>light blue</param><fixed><<boris@gnu.ai.mit.edu></fixed></x-color><x-color><param>blue</param>
|
||||
|
||||
</x-color><x-bg-color><param>blue</param><x-color><param>white</param>April 1995; updated August 1997</x-color></x-bg-color>
|
||||
|
||||
|
||||
|
||||
|
||||
Copyright (C) 1995, 1997, 2001-2013 Free Software Foundation, Inc.
|
|
@ -1,5 +1,5 @@
|
|||
% Reference Card for Org Mode
|
||||
\def\orgversionnumber{8.2.3}
|
||||
\def\orgversionnumber{8.2.4}
|
||||
\def\versionyear{2013} % latest update
|
||||
\input emacsver.tex
|
||||
|
||||
|
|
|
@ -1,3 +1,37 @@
|
|||
2013-11-28 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* Makefile.in (${leimdir}/leim-list.el):
|
||||
* leim-ext.el: Change method for getting comments in the output
|
||||
to one that does not fool lisp/compile-main's no-byte-compile test.
|
||||
|
||||
2013-11-27 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* Makefile.in (bootstrap-clean): No need to delete .elc,
|
||||
lisp/ rules will do that.
|
||||
|
||||
* Makefile.in (extraclean): New.
|
||||
(bootstrap-clean): Move ja-dic deletion to extraclean.
|
||||
|
||||
Move ja-dic, quail, leim-list.el to ../lisp/leim.
|
||||
* Makefile.in (leimdir): New variable.
|
||||
(TIT_GB, TIT_BIG5, MISC, changed.tit, changed.misc)
|
||||
(${leimdir}/leim-list.el, ${leimdir}/ja-dic/ja-dic.el):
|
||||
Generate in $leimdir.
|
||||
(all): Remove compilation, add ja-dic.
|
||||
(leim-list.el): Now PHONY.
|
||||
(setwins, compile-targets, compile-main, clean, mostlyclean)
|
||||
(extraclean): Remove.
|
||||
(bootstrap-clean): Delete all generated files.
|
||||
* README: Update for moved leim/ directory.
|
||||
* leim-ext.el (ucs-input-activate, hangul-input-method-activate):
|
||||
Remove manual autoloads; now in loaddefs.el.
|
||||
Disable byte-compile, version-control, autoloads in the output.
|
||||
* quail: Move to ../lisp/leim.
|
||||
|
||||
2013-11-23 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* Makefile.in (RUN_EMACS): Empty EMACSLOADPATH rather than unsetting.
|
||||
|
||||
2013-11-04 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* Makefile.in (RUN_EMACS): Don't set LC_ALL=C. (Bug#15260)
|
||||
|
|
148
leim/Makefile.in
148
leim/Makefile.in
|
@ -26,58 +26,54 @@ SHELL = @SHELL@
|
|||
# Here are the things that we expect ../configure to edit.
|
||||
srcdir=@srcdir@
|
||||
|
||||
# Where the generated files go.
|
||||
leimdir = ${srcdir}/../lisp/leim
|
||||
|
||||
# Which Emacs to use to convert TIT files to Emacs Lisp files,
|
||||
# byte-compile Emacs Lisp files, and generate the file leim-list.el.
|
||||
# and generate the file leim-list.el.
|
||||
EMACS = ../src/emacs
|
||||
|
||||
# How to run Emacs.
|
||||
# Prevent any setting of EMACSLOADPATH in user environment causing problems.
|
||||
RUN_EMACS = unset EMACSLOADPATH; "${EMACS}" -batch \
|
||||
--no-site-file --no-site-lisp
|
||||
RUN_EMACS = EMACSLOADPATH= "${EMACS}" -batch --no-site-file --no-site-lisp
|
||||
|
||||
MKDIR_P = @MKDIR_P@
|
||||
|
||||
# Files generated from TIT dictionaries for Chinese GB character set.
|
||||
TIT_GB=\
|
||||
quail/CCDOSPY.el \
|
||||
quail/Punct.el \
|
||||
quail/QJ.el \
|
||||
quail/SW.el \
|
||||
quail/TONEPY.el
|
||||
${leimdir}/quail/CCDOSPY.el \
|
||||
${leimdir}/quail/Punct.el \
|
||||
${leimdir}/quail/QJ.el \
|
||||
${leimdir}/quail/SW.el \
|
||||
${leimdir}/quail/TONEPY.el
|
||||
|
||||
# Files generated from TIT dictionaries for Chinese BIG5 character set.
|
||||
TIT_BIG5=\
|
||||
quail/4Corner.el \
|
||||
quail/ARRAY30.el \
|
||||
quail/ECDICT.el \
|
||||
quail/ETZY.el \
|
||||
quail/Punct-b5.el \
|
||||
quail/PY-b5.el \
|
||||
quail/QJ-b5.el \
|
||||
quail/ZOZY.el
|
||||
${leimdir}/quail/4Corner.el \
|
||||
${leimdir}/quail/ARRAY30.el \
|
||||
${leimdir}/quail/ECDICT.el \
|
||||
${leimdir}/quail/ETZY.el \
|
||||
${leimdir}/quail/Punct-b5.el \
|
||||
${leimdir}/quail/PY-b5.el \
|
||||
${leimdir}/quail/QJ-b5.el \
|
||||
${leimdir}/quail/ZOZY.el
|
||||
|
||||
CHINESE_TIT=${TIT_GB} ${TIT_BIG5}
|
||||
|
||||
MISC= \
|
||||
quail/tsang-b5.el \
|
||||
quail/quick-b5.el \
|
||||
quail/tsang-cns.el \
|
||||
quail/quick-cns.el \
|
||||
quail/PY.el \
|
||||
quail/ZIRANMA.el \
|
||||
quail/CTLau.el \
|
||||
quail/CTLau-b5.el
|
||||
${leimdir}/quail/tsang-b5.el \
|
||||
${leimdir}/quail/quick-b5.el \
|
||||
${leimdir}/quail/tsang-cns.el \
|
||||
${leimdir}/quail/quick-cns.el \
|
||||
${leimdir}/quail/PY.el \
|
||||
${leimdir}/quail/ZIRANMA.el \
|
||||
${leimdir}/quail/CTLau.el \
|
||||
${leimdir}/quail/CTLau-b5.el
|
||||
|
||||
## The generated .el files.
|
||||
TIT_MISC=${CHINESE_TIT} ${MISC}
|
||||
|
||||
.SUFFIXES: .elc .el
|
||||
|
||||
.el.elc:
|
||||
@echo Compiling $<
|
||||
@${RUN_EMACS} -l international/quail -f batch-byte-compile $<
|
||||
|
||||
all: leim-list.el compile-main
|
||||
all: ${leimdir}/leim-list.el ${leimdir}/ja-dic/ja-dic.el
|
||||
.PHONY: all
|
||||
|
||||
TIT_SOURCES= \
|
||||
|
@ -107,10 +103,10 @@ ${CHINESE_TIT}: changed.tit
|
|||
## quail/%.el: CXTERM-DIC/%.tit
|
||||
## It doesn't seem possible to do this with VPATH and suffix rules.
|
||||
changed.tit: ${TIT_SOURCES}
|
||||
@${MKDIR_P} quail
|
||||
@${MKDIR_P} ${leimdir}/quail
|
||||
${RUN_EMACS} -l titdic-cnv \
|
||||
-f batch-titdic-convert -dir quail ${srcdir}/CXTERM-DIC; \
|
||||
echo "changed" > $@
|
||||
-f batch-titdic-convert -dir ${leimdir}/quail ${srcdir}/CXTERM-DIC
|
||||
echo "changed" > $@
|
||||
|
||||
MISC_SOURCES= \
|
||||
${srcdir}/MISC-DIC/CTLau-b5.html \
|
||||
|
@ -124,75 +120,41 @@ ${MISC}: changed.misc
|
|||
@true
|
||||
|
||||
changed.misc: ${MISC_SOURCES}
|
||||
@${MKDIR_P} quail
|
||||
@${MKDIR_P} ${leimdir}/quail
|
||||
${RUN_EMACS} -l titdic-cnv \
|
||||
-f batch-miscdic-convert -dir quail ${srcdir}/MISC-DIC; \
|
||||
echo "changed" > $@
|
||||
-f batch-miscdic-convert -dir ${leimdir}/quail ${srcdir}/MISC-DIC
|
||||
echo "changed" > $@
|
||||
|
||||
leim-list.el: ${TIT_MISC} ${srcdir}/leim-ext.el
|
||||
rm -f leim-list.el
|
||||
if [ "`cd ${srcdir} && /bin/pwd`" = "`/bin/pwd`" ] ; then \
|
||||
${RUN_EMACS} -l international/quail \
|
||||
--eval "(update-leim-list-file \".\")" ; \
|
||||
else \
|
||||
${RUN_EMACS} -l international/quail \
|
||||
--eval "(update-leim-list-file \".\" (unmsys--file-name \"${srcdir}\"))" ; \
|
||||
fi
|
||||
sed -n '/^[^;]/ p' < ${srcdir}/leim-ext.el >> $@
|
||||
.PHONY: leim-list.el
|
||||
leim-list.el: ${leimdir}/leim-list.el
|
||||
|
||||
$(srcdir)/ja-dic/ja-dic.el: $(srcdir)/SKK-DIC/SKK-JISYO.L
|
||||
@$(MKDIR_P) $(srcdir)/ja-dic
|
||||
${leimdir}/leim-list.el: ${TIT_MISC} ${srcdir}/leim-ext.el
|
||||
rm -f $@
|
||||
${RUN_EMACS} -l international/quail \
|
||||
--eval "(update-leim-list-file (unmsys--file-name \"${leimdir}\"))"
|
||||
sed -n -e '/^[^;]/p' -e 's/^;\(;*\)inc /;\1 /p' < ${srcdir}/leim-ext.el >> $@
|
||||
|
||||
${leimdir}/ja-dic/ja-dic.el: $(srcdir)/SKK-DIC/SKK-JISYO.L
|
||||
@$(MKDIR_P) $(leimdir)/ja-dic
|
||||
$(RUN_EMACS) -batch -l ja-dic-cnv \
|
||||
-f batch-skkdic-convert -dir "$(srcdir)/ja-dic" \
|
||||
-f batch-skkdic-convert -dir "$(leimdir)/ja-dic" \
|
||||
"$(srcdir)/SKK-DIC/SKK-JISYO.L"
|
||||
|
||||
## Following adapted from lisp/Makefile.in.
|
||||
setwins=wins="${srcdir}/ja-dic quail"; \
|
||||
[ "`cd ${srcdir} && /bin/pwd`" != "`/bin/pwd`" ] && \
|
||||
wins="$$wins ${srcdir}/quail"
|
||||
.PHONY: bootstrap-clean distclean maintainer-clean extraclean
|
||||
|
||||
.PHONY: compile-targets
|
||||
# TARGETS is set dynamically in the recursive call from `compile-main'.
|
||||
compile-targets: $(TARGETS)
|
||||
bootstrap-clean:
|
||||
rm -f ${TIT_MISC} ${leimdir}/leim-list.el changed.tit changed.misc
|
||||
|
||||
# Compile all the Elisp files that need it. Beware: it approximates
|
||||
# `no-byte-compile', so watch out for false-positives!
|
||||
.PHONY: compile-main
|
||||
compile-main: ${TIT_MISC} $(srcdir)/ja-dic/ja-dic.el
|
||||
@($(setwins); \
|
||||
els=`echo "$$wins " | sed -e 's| |/*.el |g'`; \
|
||||
for el in $$els; do \
|
||||
test -f $$el || continue; \
|
||||
test ! -f $${el}c && GREP_OPTIONS= grep '^;.*no-byte-compile: t' $$el > /dev/null && continue; \
|
||||
echo "$${el}c"; \
|
||||
done | xargs echo) | \
|
||||
while read chunk; do \
|
||||
$(MAKE) $(MFLAGS) compile-targets EMACS="$(EMACS)" TARGETS="$$chunk"; \
|
||||
done
|
||||
|
||||
.PHONY: clean mostlyclean bootstrap-clean distclean maintainer-clean extraclean
|
||||
|
||||
clean mostlyclean:
|
||||
rm -f ${TIT_MISC} ${TIT_MISC:.el=.elc} \
|
||||
leim-list.el changed.tit changed.misc
|
||||
|
||||
# The following target is needed because the `clean' target only removes
|
||||
# TIT-generated files and doesn't touch compiled Quail packages. But
|
||||
# bootstrapping should not leave non-fresh .elc files behind.
|
||||
bootstrap-clean: clean
|
||||
$(setwins); for w in $$wins; do rm -f $$w/*.elc; done
|
||||
|
||||
distclean: clean
|
||||
-[ "`cd ${srcdir} && /bin/pwd`" != "`/bin/pwd`" ] && rm -rf quail
|
||||
distclean:
|
||||
rm -f Makefile
|
||||
|
||||
maintainer-clean: distclean bootstrap-clean
|
||||
|
||||
extraclean: maintainer-clean
|
||||
-rm -f *~ \#* */*~ */\#*
|
||||
## We do not delete ja-dic, even in a bootstrap, because it rarely
|
||||
## changes and is slow to regenerate.
|
||||
## TODO? Could consider doing the same with TIT_MISC, though those
|
||||
## are much faster to generate.
|
||||
extraclean:
|
||||
rm -rf ${leimdir}/ja-dic
|
||||
|
||||
.PHONY: check-declare
|
||||
|
||||
check-declare:
|
||||
$(RUN_EMACS) -l check-declare \
|
||||
--eval '(check-declare-directory (unmsys--file-name "$(srcdir)"))'
|
||||
### Makefile.in ends here
|
||||
|
|
24
leim/README
24
leim/README
|
@ -20,24 +20,22 @@ This directory contains various dictionaries for Chinese input
|
|||
methods. These dictionaries are automatically converted to Quail
|
||||
packages (Emacs Lisp source files) by `make'.
|
||||
|
||||
quail:
|
||||
|
||||
This directory contains Emacs Lisp source files for Quail packages.
|
||||
|
||||
SKK-DIC:
|
||||
|
||||
This directory contains source dictionary for Japanese input method
|
||||
distributed with SKK (Japanese input method run with Mule). But, you
|
||||
don't need this file because we distribute an Emacs Lisp source file
|
||||
ja-dic/ja-dic.el which has already been converted from the source
|
||||
dictionary (See below).
|
||||
distributed with SKK (Japanese input method run with Mule).
|
||||
|
||||
ja-dic:
|
||||
|
||||
This directory contains Emacs Lisp source file ja-dic.el which is
|
||||
generated from a source dictionary in SKK-DIC directory. The
|
||||
inclusion of this file is for users convenience because it takes
|
||||
rather long time to generate it.
|
||||
The above source files are used to generate the following outputs:
|
||||
|
||||
../lisp/leim/quail:
|
||||
|
||||
This directory contains Emacs Lisp source files for Quail packages.
|
||||
|
||||
../lisp/leim/ja-dic:
|
||||
|
||||
This directory contains Emacs Lisp source file ja-dic.el,
|
||||
generated from a source dictionary in SKK-DIC directory.
|
||||
|
||||
|
||||
This file is part of GNU Emacs.
|
||||
|
|
|
@ -37,21 +37,9 @@
|
|||
(eval-after-load "quail/Punct-b5"
|
||||
'(quail-defrule " " ? nil t))
|
||||
|
||||
(autoload 'ucs-input-activate "quail/uni-input"
|
||||
"Activate UCS input method.
|
||||
With arg, activate UCS input method if and only if arg is positive.
|
||||
|
||||
While this input method is active, the variable
|
||||
`input-method-function' is bound to the function `ucs-input-method'.")
|
||||
|
||||
(register-input-method "ucs" "UTF-8" 'ucs-input-activate "U+"
|
||||
"Unicode input as hex in the form Uxxxx.")
|
||||
|
||||
(autoload 'hangul-input-method-activate "quail/hangul"
|
||||
"Activate Hangul input method INPUT-METHOD.
|
||||
FUNC is a function to handle input key.
|
||||
HELP-TEXT is a text set in `hangul-input-method-help-text'.")
|
||||
|
||||
(register-input-method
|
||||
"korean-hangul"
|
||||
"UTF-8"
|
||||
|
@ -88,3 +76,17 @@ HELP-TEXT is a text set in `hangul-input-method-help-text'.")
|
|||
'hangul390-input-method
|
||||
"Input method: korean-hangul390 (mode line indicator:한390)\n\nHangul 3-Bulsik 390 input method.")
|
||||
|
||||
;; Following lines are marked such that Makefile adds them to output.
|
||||
;; leim-list-header adds "coding: utf-8"; we could move that here,
|
||||
;; unless others are using that stuff to generate their own leim files.
|
||||
;; TODO? Better to add leim-list-footer?
|
||||
|
||||
;;inc Local Variables:
|
||||
;;inc no-byte-compile: t
|
||||
;;inc version-control: never
|
||||
;;inc no-update-autoloads: t
|
||||
;;inc End:
|
||||
|
||||
;;;inc leim-list.el ends here
|
||||
|
||||
;;; leim-ext.el ends here
|
||||
|
|
|
@ -43,6 +43,21 @@ getgroups (int n _GL_UNUSED, GETGROUPS_T *groups _GL_UNUSED)
|
|||
# define GETGROUPS_ZERO_BUG 0
|
||||
# endif
|
||||
|
||||
/* On OS X 10.6 and later, use the usual getgroups, not the one
|
||||
supplied when _DARWIN_C_SOURCE is defined. _DARWIN_C_SOURCE is
|
||||
normally defined, since it means "conform to POSIX, but add
|
||||
non-POSIX extensions even if that violates the POSIX namespace
|
||||
rules", which is what we normally want. But with getgroups there
|
||||
is an inconsistency, and _DARWIN_C_SOURCE means "change getgroups()
|
||||
so that it no longer works right". The BUGS section of compat(5)
|
||||
says that the behavior is dubious if you compile different sections
|
||||
of a program with different _DARWIN_C_SOURCE settings, so fix only
|
||||
the offending symbol. */
|
||||
# ifdef __APPLE__
|
||||
int posix_getgroups (int, gid_t []) __asm ("_getgroups");
|
||||
# define getgroups posix_getgroups
|
||||
# endif
|
||||
|
||||
/* On at least Ultrix 4.3 and NextStep 3.2, getgroups (0, NULL) always
|
||||
fails. On other systems, it returns the number of supplemental
|
||||
groups for the process. This function handles that special case
|
||||
|
|
697
lisp/ChangeLog
697
lisp/ChangeLog
|
@ -1,3 +1,678 @@
|
|||
2013-12-07 Lars Magne Ingebrigtsen <larsi@gnus.org>
|
||||
|
||||
* net/shr.el (shr-tag-img): Don't bug out on <img src="">
|
||||
data.
|
||||
|
||||
2013-12-06 Michael Albinus <michael.albinus@gmx.de>
|
||||
|
||||
* progmodes/compile.el (compilation-start):
|
||||
* progmodes/grep.el (rgrep): Revert change 2012-12-20T11:15:38Z!michael.albinus@gmx.de.
|
||||
|
||||
* net/tramp-sh.el (tramp-sh-handle-start-file-process):
|
||||
Handle long command lines, lasting from "sh -c ...". (Bug#16045)
|
||||
|
||||
2013-12-06 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* progmodes/ruby-mode.el (ruby-syntax-propertize-function): Touch
|
||||
up the last change.
|
||||
|
||||
2013-12-06 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* progmodes/octave.el (inferior-octave-prompt): Use shy groups.
|
||||
(inferior-octave-startup): Always use "octave> " for prompt.
|
||||
(octave-goto-function-definition)
|
||||
(octave-sync-function-file-names)
|
||||
(octave-find-definition-default-filename): Remove redundant backquotes.
|
||||
|
||||
2013-12-06 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* progmodes/ruby-mode.el (ruby-mode-syntax-table): Don't modify
|
||||
syntax for `?'.
|
||||
(ruby-expr-beg): Expect that `!' will have syntax class "symbol"
|
||||
where appropriate already.
|
||||
(ruby-syntax-propertize-function): Propertize `?' and `!' at the
|
||||
end of method names (Bug#15874).
|
||||
|
||||
2013-12-06 Juri Linkov <juri@jurta.org>
|
||||
|
||||
* isearch.el (isearch--saved-overriding-local-map):
|
||||
New internal variable.
|
||||
(isearch-mode): Set it to the initial value of
|
||||
`overriding-terminal-local-map'.
|
||||
(isearch-pre-command-hook): Compare `overriding-terminal-local-map'
|
||||
with `isearch--saved-overriding-local-map'. (Bug#16035)
|
||||
|
||||
2013-12-06 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* progmodes/octave.el (inferior-octave-completion-table): Turn
|
||||
back into function, use `completion-table-with-cache'
|
||||
(Bug#11906). Update all references.
|
||||
|
||||
* minibuffer.el (completion-table-with-cache): New function.
|
||||
|
||||
2013-12-05 Cameron Desautels <camdez@gmail.com> (tiny change)
|
||||
|
||||
* emacs-lisp/regexp-opt.el (regexp-opt-charset): Fix ^ (bug#16046).
|
||||
|
||||
2013-12-05 Teodor Zlatanov <tzz@lifelogs.com>
|
||||
|
||||
* net/eww.el (eww-current-source): New variable to store page
|
||||
source.
|
||||
(eww-display-html, eww-mode, eww-save-history)
|
||||
(eww-restore-history): Use it.
|
||||
(eww-view-source): New command to view page source.
|
||||
Opportunistically uses `html-mode' to highlight the buffer.
|
||||
(eww-mode-map): Install it.
|
||||
|
||||
2013-12-05 Michael Albinus <michael.albinus@gmx.de>
|
||||
|
||||
* net/dbus.el (dbus-unregister-service)
|
||||
(dbus-escape-as-identifier, dbus-unescape-from-identifier):
|
||||
Fix docstring.
|
||||
(dbus-unregister-service): Skip :serial entries in
|
||||
`dbus-registered-objects-table'.
|
||||
(dbus-byte-array-to-string): New optional arg MULTIBYTE.
|
||||
|
||||
2013-12-04 Teodor Zlatanov <tzz@lifelogs.com>
|
||||
|
||||
* emacs-lisp/lisp-mnt.el (lm-keywords-list): Trim whitespace
|
||||
around keywords with extra `split-string' argument.
|
||||
|
||||
2013-12-04 Martin Rudalics <rudalics@gmx.at>
|
||||
|
||||
* windmove.el (windmove-other-window-loc): Handle navigation
|
||||
between windows (excluding the minibuffer window - Bug#16017).
|
||||
|
||||
2013-12-04 Michael Albinus <michael.albinus@gmx.de>
|
||||
|
||||
* net/dbus.el (dbus-byte-array-to-string): Accept also byte arrays
|
||||
in D-Bus type syntax.
|
||||
(dbus-unescape-from-identifier): Use `byte-to-string' in order to
|
||||
preserve unibyte strings. (Bug#16048)
|
||||
|
||||
2013-12-04 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* emacs-lisp/eldoc.el (eldoc-minibuffer-message):
|
||||
Call force-mode-line-update is the proper buffer (bug#16042).
|
||||
|
||||
2013-12-04 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* vc/log-edit.el (log-edit-add-new-comment): Rename to
|
||||
`log-edit-remember-comment', make argument optional. Adjust all
|
||||
callers.
|
||||
(log-edit-mode): Add `log-edit-remember-comment' to
|
||||
`kill-buffer-hook' locally.
|
||||
(log-edit-kill-buffer): Don't remember comment explicitly since
|
||||
the buffer is killed anyway.
|
||||
|
||||
2013-12-04 Juri Linkov <juri@jurta.org>
|
||||
|
||||
* isearch.el (isearch-mode, isearch-done): Don't set arg LOCAL in
|
||||
add-hook and remove-hook for multi-buffer search. (Bug#16035)
|
||||
|
||||
2013-12-03 Tom Regner <tom@goochesa.de> (tiny change)
|
||||
|
||||
* notifications.el (notifications-close-notification): Call the
|
||||
D-Bus method with ID being a `:uint32'. (Bug#16030)
|
||||
|
||||
2013-12-03 Katsumi Yamaoka <yamaoka@jpl.org>
|
||||
|
||||
* net/eww.el (eww-render): Don't pass arg to eww-display-image.
|
||||
|
||||
2013-12-03 Juri Linkov <juri@jurta.org>
|
||||
|
||||
* progmodes/compile.el (compilation-start): Rename window alist
|
||||
entry `no-display-ok' to `allow-no-window'.
|
||||
|
||||
* simple.el (shell-command): Add window alist entry
|
||||
`allow-no-window' to `display-buffer'.
|
||||
(async-shell-command): Doc fix.
|
||||
|
||||
* window.el (display-buffer-no-window): New action function.
|
||||
(display-buffer-alist, display-buffer): Doc fix. (Bug#13594)
|
||||
|
||||
2013-12-02 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* vc/log-edit.el (log-edit-set-header): Extract from
|
||||
`log-edit-toggle-header'.
|
||||
(log-edit-extract-headers): Separate the summary, when extracted
|
||||
from header, from the rest of the message with an empty line.
|
||||
|
||||
* vc/vc-git.el (vc-git-log-edit-toggle-amend): Move the summary
|
||||
line, if present, to the Summary header.
|
||||
|
||||
2013-12-02 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* epa-file.el (epa-file-insert-file-contents): Ensure we insert text
|
||||
in current-buffer (bug#16029).
|
||||
|
||||
2013-12-02 Helmut Eller <eller.helmut@gmail.com>
|
||||
|
||||
* emacs-lisp/debug.el (debugger-toggle-locals): New command.
|
||||
(debugger-mode-map): Bind it.
|
||||
(debugger--backtrace-base): New function.
|
||||
(debugger-eval-expression): Use it.
|
||||
(debugger-frame-number): Skip local vars when present.
|
||||
(debugger--locals-visible-p, debugger--insert-locals)
|
||||
(debugger--show-locals, debugger--hide-locals): New functions.
|
||||
|
||||
2013-12-02 Michael Albinus <michael.albinus@gmx.de>
|
||||
|
||||
* net/tramp-sh.el (tramp-remote-process-environment): Do not set
|
||||
"LC_ALL".
|
||||
(tramp-get-remote-locale): New defun.
|
||||
(tramp-open-connection-setup-interactive-shell): Use it.
|
||||
|
||||
2013-12-02 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* subr.el (process-live-p): Return nil for non-process. (Bug#16023)
|
||||
|
||||
* progmodes/sh-script.el (sh-shell-process):
|
||||
* progmodes/octave.el (inferior-octave-process-live-p):
|
||||
* progmodes/gdb-mi.el (gdb-delchar-or-quit)
|
||||
(gdb-inferior-io-sentinel):
|
||||
* emacs-lock.el (emacs-lock-live-process-p): All uses changed.
|
||||
|
||||
2013-12-02 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* vc/log-edit.el (log-edit-kill-buffer): Move the use of
|
||||
`save-selected-window' to `log-edit-hide-buf'. This makes
|
||||
`log-edit-show-files' idempotent.
|
||||
(log-edit-show-files): Mark the new window as dedicated.
|
||||
|
||||
2013-12-02 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* vc/log-edit.el (log-edit-mode-map): Add binding for
|
||||
`log-edit-kill-biffer'.
|
||||
(log-edit-hide-buf): Add a FIXME comment.
|
||||
(log-edit-add-new-comment): New function, extracted from
|
||||
`log-edit-done'.
|
||||
(log-edit-done, log-edit-add-to-changelog): Use it.
|
||||
(log-edit-kill-buffer): New command.
|
||||
|
||||
2013-12-01 Lars Magne Ingebrigtsen <larsi@gnus.org>
|
||||
|
||||
* net/eww.el (eww-mode-map): Have `q' do a normal `quit-window'
|
||||
instead of killing the buffer.
|
||||
|
||||
2013-12-01 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* simple.el (newline): Mention `electric-indent-mode' (bug#16015).
|
||||
|
||||
2013-12-01 Rüdiger Sonderfeld <ruediger@c-plusplus.de>
|
||||
|
||||
* net/eww.el (eww-form-checkbox-selected-symbol)
|
||||
(eww-form-checkbox-symbol): New customizable variable.
|
||||
(eww-form-checkbox, eww-toggle-checkbox):
|
||||
Use `eww-form-checkbox-selected-symbol' and `eww-form-checkbox-symbol'.
|
||||
|
||||
* net/shr.el (shr-prefer-media-type-alist): : New customizable variable.
|
||||
(shr--get-media-pref, shr--extract-best-source): New function.
|
||||
(shr-tag-video, shr-tag-audio): Use `shr--extract-best-source' when
|
||||
no :src tag was specified.
|
||||
|
||||
* net/eww.el (eww-use-external-browser-for-content-type): New variable.
|
||||
(eww-render): Handle `eww-use-external-browser-for-content-type'.
|
||||
Use \\` to match beginning of string instead of ^.
|
||||
(eww-browse-with-external-browser): Provide optional URL parameter.
|
||||
(eww-render): Set `eww-current-title' back to "".
|
||||
|
||||
* net/shr.el (shr-tag-video): Display content for video if no
|
||||
poster is available.
|
||||
(shr-tag-audio): Add support for <audio> tag.
|
||||
|
||||
* net/eww.el (eww-text-input-types): : New const.
|
||||
(eww-process-text-input): Treat input types in
|
||||
`eww-text-input-types' as text.
|
||||
|
||||
* net/shr.el (shr-tag-table): Fix comment typo.
|
||||
|
||||
2013-12-01 Lars Magne Ingebrigtsen <larsi@gnus.org>
|
||||
|
||||
* net/eww.el (eww-follow-link): New command to avoid reloading
|
||||
pages when we follow #target links (bug#15243).
|
||||
(eww-quit): Special mode buffers shouldn't query before exiting.
|
||||
|
||||
2013-12-01 Kenjiro NAKAYAMA <nakayamakenjiro@gmail.com>
|
||||
|
||||
* net/eww.el (eww-tag-select): Support <optgroup> tags in <select>
|
||||
forms.
|
||||
|
||||
2013-12-01 Lars Magne Ingebrigtsen <larsi@gnus.org>
|
||||
|
||||
* net/eww.el (eww-restore-history): Update the window title after
|
||||
moving in the history.
|
||||
(eww-current-dom): New variable used to save the current DOM.
|
||||
|
||||
2013-12-01 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* vc/log-edit.el (log-edit-mode-map): Add binding for
|
||||
`log-edit-beginning-of-line'.
|
||||
(log-edit-setup-add-author): New user option.
|
||||
(log-edit-beginning-of-line): New command.
|
||||
(log-edit): Move major mode call above the contents setup so that
|
||||
the local variable values are already applied.
|
||||
(log-edit): Only insert "Author: " when
|
||||
`log-edit-setup-add-author' is non-nil.
|
||||
(log-edit): When SETUP is non-nil, position point after ": "
|
||||
instead of point-min.
|
||||
|
||||
2013-12-01 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* startup.el (command-line): Warn if ~/emacs.d is in load-path.
|
||||
|
||||
2013-11-30 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* startup.el (fancy-splash-frame): On MS-Windows, trigger
|
||||
redisplay to make sure the initial frame gets a chance to become
|
||||
visible. (Bug#16014)
|
||||
|
||||
2013-11-30 Martin Rudalics <rudalics@gmx.at>
|
||||
|
||||
Support resizing frames and windows pixelwise.
|
||||
* cus-start.el (frame-resize-pixelwise)
|
||||
(window-resize-pixelwise): New entries.
|
||||
* emacs-lisp/debug.el (debug): Use window-total-height instead
|
||||
of window-total-size.
|
||||
* frame.el (tool-bar-lines-needed): Defalias to tool-bar-height.
|
||||
* help.el (describe-bindings-internal): Call help-buffer
|
||||
(temp-buffer-max-width): New option.
|
||||
(resize-temp-buffer-window, help-window-setup)
|
||||
(with-help-window): Rewrite.
|
||||
* mouse.el (mouse-drag-line): Rewrite. Add key bindings for
|
||||
dragging dividers.
|
||||
* window.el (frame-char-size, window-min-pixel-height)
|
||||
(window-safe-min-pixel-height, window-safe-min-pixel-width)
|
||||
(window-min-pixel-width, window-safe-min-pixel-size)
|
||||
(window-combination-p, window-safe-min-size)
|
||||
(window-resizable-p, window--size-to-pixel)
|
||||
(window--pixel-to-size, window--resize-apply-p): New functions.
|
||||
(window-safe-min-height): Fix doc-string.
|
||||
(window-size, window-min-size, window--min-size-1)
|
||||
(window-sizable, window-sizable-p, window--min-delta-1)
|
||||
(window-min-delta, window--max-delta-1, window-max-delta)
|
||||
(window--resizable, window--resizable-p, window-resizable)
|
||||
(window-full-height-p, window-full-width-p, window-at-side-p)
|
||||
(window--in-direction-2, window-in-direction)
|
||||
(window--resize-reset-1, window--resize-mini-window)
|
||||
(window-resize, window-resize-no-error)
|
||||
(window--resize-child-windows-normal)
|
||||
(window--resize-child-windows, window--resize-siblings)
|
||||
(window--resize-this-window, window--resize-root-window)
|
||||
(window--resize-root-window-vertically)
|
||||
(adjust-window-trailing-edge, enlarge-window, shrink-window)
|
||||
(maximize-window, minimize-window, delete-window)
|
||||
(quit-restore-window, window-split-min-size, split-window)
|
||||
(balance-windows-2, balance-windows)
|
||||
(balance-windows-area-adjust, balance-windows-area)
|
||||
(window--state-get-1, window-state-get, window--state-put-1)
|
||||
(window--state-put-2, window-state-put)
|
||||
(display-buffer-record-window, window--display-buffer):
|
||||
Make functions handle pixelwise sizing of windows.
|
||||
(display-buffer--action-function-custom-type)
|
||||
(display-buffer-fallback-action):
|
||||
Add display-buffer-in-previous-window.
|
||||
(display-buffer-use-some-window): Resize window to height it had
|
||||
before.
|
||||
(fit-window-to-buffer-horizontally): New option.
|
||||
(fit-frame-to-buffer): Describe new values.
|
||||
(fit-frame-to-buffer-bottom-margin): Replace with
|
||||
fit-frame-to-buffer-margins.
|
||||
(window--sanitize-margin): New function.
|
||||
(fit-frame-to-buffer, fit-window-to-buffer): Rewrite completely
|
||||
using window-text-pixel-size.
|
||||
|
||||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* emacs-lisp/bytecomp.el (byte-compile-form):
|
||||
Make the `interactive-only' warning like the `obsolete' one.
|
||||
* comint.el (comint-run):
|
||||
* files.el (insert-file-literally, insert-file):
|
||||
* replace.el (replace-string, replace-regexp):
|
||||
* simple.el (beginning-of-buffer, end-of-buffer, delete-backward-char)
|
||||
(goto-line, insert-buffer, next-line, previous-line):
|
||||
Tweak `interactive-only' spec.
|
||||
|
||||
Stop keeping (most) generated cedet grammar files in the repository.
|
||||
* Makefile.in (semantic): New.
|
||||
(compile-main): Depend on semantic.
|
||||
|
||||
2013-11-29 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* net/newst-reader.el (newsticker-html-renderer): Default to SHR if
|
||||
available. Suggested by Clément B. <barthele1u@etu.univ-lorraine.fr>.
|
||||
|
||||
* uniquify.el (uniquify-buffer-name-style): Change default.
|
||||
|
||||
* loadup.el: Preload "uniquify".
|
||||
|
||||
* time.el (display-time-update): Update all mode lines (bug#15999).
|
||||
|
||||
* electric.el (electric-indent-mode): Enable by default.
|
||||
* loadup.el: Preload "electric".
|
||||
|
||||
2013-11-29 Bozhidar Batsov <bozhidar@batsov.com>
|
||||
|
||||
* emacs-lisp/helpers.el (string-empty-p): New function.
|
||||
(string-blank-p): New function.
|
||||
|
||||
2013-11-29 Andreas Politz <politza@hochschule-trier.de>
|
||||
|
||||
* imenu.el (imenu--index-alist): Add missing dot to the docstring
|
||||
(Bug#14029).
|
||||
|
||||
2013-11-29 Andreas Politz <politza@fh-trier.de>
|
||||
* imenu.el (imenu--subalist-p): Don't error on non-conses and
|
||||
allow non-lambda lists as functions.
|
||||
(imenu--in-alist): Don't recurse into non-subalists.
|
||||
(imenu): Don't pass function itself as an argument (Bug#14029).
|
||||
|
||||
2013-11-29 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* progmodes/python.el (python-mode-map): Remove binding for ":".
|
||||
(python-indent-electric-colon): Remove command.
|
||||
(python-indent-post-self-insert-function): Integrate the previous code
|
||||
of python-indent-electric-colon. Make it conditional on
|
||||
electric-indent-mode.
|
||||
(python-mode): Add ?: to electric-indent-chars.
|
||||
Move python-indent-post-self-insert-function to the end of
|
||||
post-self-insert-hook.
|
||||
|
||||
2013-11-28 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* doc-view.el (doc-view-goto-page): Update mode-line.
|
||||
|
||||
* vc/vc-dispatcher.el (vc-log-edit): Setup the Summary&Author headers.
|
||||
|
||||
2013-11-27 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* international/charprop.el, international/uni-bidi.el:
|
||||
* international/uni-category.el, international/uni-combining.el:
|
||||
* international/uni-comment.el, international/uni-decimal.el:
|
||||
* international/uni-decomposition.el, international/uni-digit.el:
|
||||
* international/uni-lowercase.el, international/uni-mirrored.el:
|
||||
* international/uni-name.el, international/uni-numeric.el:
|
||||
* international/uni-old-name.el, international/uni-titlecase.el:
|
||||
* international/uni-uppercase.el:
|
||||
Remove generated files from VCS repository.
|
||||
|
||||
2013-11-27 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* filenotify.el (file-notify-add-watch): Don't special-case
|
||||
w32notify when computing the directory to watch.
|
||||
|
||||
2013-11-27 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
Make bootstrap without generated uni-*.el files possible again.
|
||||
* loadup.el: Update command-line-args checking for unidata-gen.
|
||||
Add vc to load-path to allow loading vc-bzr when writing uni-*.el.
|
||||
* composite.el, international/characters.el:
|
||||
Handle unicode tables being undefined.
|
||||
|
||||
Move ja-dic, quail, leim-list.el from ../leim to a leim subdirectory.
|
||||
* Makefile.in (setwins_for_subdirs): Skip leim/ directory.
|
||||
(compile-main): Depend on leim rule.
|
||||
(leim): New rule.
|
||||
* loadup.el: Move leim-list.el to leim/ subdirectory.
|
||||
* startup.el (normal-top-level): No more leim directory.
|
||||
* international/ja-dic-cnv.el (skkdic-convert):
|
||||
Disable version-control and autoloads in output files.
|
||||
* international/titdic-cnv.el (titdic-convert, miscdic-convert):
|
||||
Disable version-control and autoloads in output files.
|
||||
* leim/quail: Move here from ../leim.
|
||||
* leim/quail/hangul.el (hangul-input-method-activate):
|
||||
Add autoload cookie.
|
||||
(generated-autoload-load-name): Set file-local value.
|
||||
* leim/quail/uni-input.el (ucs-input-activate): Add autoload cookie.
|
||||
(generated-autoload-load-name): Set file-local value.
|
||||
|
||||
2013-11-26 Kenjiro NAKAYAMA <knakayam@redhat.com> (tiny change)
|
||||
|
||||
* net/eww.el (eww-bookmark-browse): Use 'eww-browse-url'.
|
||||
(eww-add-bookmark): ask confirmation when add to bookmarks
|
||||
(eww-quit): ask confirmation before quitting eww
|
||||
|
||||
2013-11-26 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* vc/vc.el (vc-diff-internal): Use *-dos coding-system when
|
||||
reading output from Diff on MS-Windows and MS-DOS.
|
||||
|
||||
2013-11-26 Bozhidar Batsov <bozhidar@batsov.com>
|
||||
|
||||
* emacs-lisp/helpers.el (string-reverse): New function.
|
||||
|
||||
2013-11-26 Michael Albinus <michael.albinus@gmx.de>
|
||||
|
||||
* net/tramp.el (tramp-file-name-regexp-unified): Support IPv6 host
|
||||
names on MS Windows, like "/[::1]:".
|
||||
|
||||
* net/tramp-sh.el (tramp-sh-handle-insert-directory): Accept nil
|
||||
SWITCHES.
|
||||
|
||||
2013-11-26 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* progmodes/python.el (python-indent-guess-indent-offset):
|
||||
Avoid corner-case error. (Bug#15975)
|
||||
|
||||
Preload leim-list.el. (Bug#4789)
|
||||
* loadup.el: Load leim-list.el when found.
|
||||
* startup.el (normal-top-level): Skip re-loading leim/leim-list.el.
|
||||
|
||||
2013-11-25 Bozhidar Batsov <bozhidar@batsov.com>
|
||||
|
||||
* emacs-lisp/bytecomp.el (byte-compile-form): Fix a typo.
|
||||
|
||||
* emacs-lisp/helpers.el (string-join): New function.
|
||||
|
||||
2013-11-25 Sebastian Wiesner <lunaryorn@gmail.com> (tiny change)
|
||||
|
||||
* emacs-lisp/bytecomp.el (byte-compile-interactive-only-functions):
|
||||
Mark as obsolete and replace it with a symbol property.
|
||||
(byte-compile-form): Use new 'interactive-only property.
|
||||
* comint.el, files.el, replace.el, simple.el:
|
||||
Apply new 'interactive-only properly.
|
||||
|
||||
2013-11-25 Martin Rudalics <rudalics@gmx.at>
|
||||
|
||||
* window.el (display-buffer-at-bottom): Make sure that
|
||||
split-window-sensibly creates the new window on bottom
|
||||
(Bug#15961).
|
||||
|
||||
2013-11-23 David Kastrup <dak@gnu.org>
|
||||
|
||||
* vc/smerge-mode.el (smerge-ediff): Choose default buffer names based
|
||||
on the conflict markers when available.
|
||||
(smerge--get-marker): New function.
|
||||
(smerge-end-re, smerge-base-re): Add subgroup.
|
||||
|
||||
2013-11-25 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* frame.el (handle-focus-in, handle-focus-out): Add missing
|
||||
interactive spec.
|
||||
|
||||
2013-11-25 Michael Albinus <michael.albinus@gmx.de>
|
||||
|
||||
* net/tramp-cmds.el (tramp-cleanup-connection): Clean up
|
||||
`tramp-current-connection' only when KEEP-PASSWORD is non-nil.
|
||||
|
||||
2013-11-25 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* play/gomoku.el: Don't use intangible property. Use lexical-binding.
|
||||
(gomoku--last-pos): New var.
|
||||
(gomoku--intangible-chars): New const.
|
||||
(gomoku--intangible): New function.
|
||||
(gomoku-mode): Use it. Derive from special-mode.
|
||||
(gomoku-move-up): Adjust line count.
|
||||
(gomoku-click, gomoku-point-y, gomoku-point-square, gomoku-goto-xy)
|
||||
(gomoku-plot-square, gomoku-init-display, gomoku-cross-qtuple):
|
||||
Simplify accordingly.
|
||||
|
||||
* frame.el (handle-focus-in, handle-focus-out): Move from frame.c.
|
||||
Remove blink-cursor code.
|
||||
(blink-cursor-timer-function, blink-cursor-suspend):
|
||||
Don't special-case GUIs.
|
||||
(blink-cursor-mode): Use focus-in/out-hook.
|
||||
|
||||
2013-11-25 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* vc/vc-git.el (vc-git-annotate-extract-revision-at-line): Make it
|
||||
work when annotation is invisible (Bug#13886).
|
||||
|
||||
2013-11-24 Simon Schubert <2@0x2c.org> (tiny change)
|
||||
|
||||
* json.el (json-alist-p): Only return non-nil if the alist has
|
||||
simple keys (Bug#13518).
|
||||
|
||||
2013-11-24 Mihir Rege <mihirrege@gmail.com> (tiny change)
|
||||
|
||||
* progmodes/js.el (js--ctrl-statement-indentation): Fix indent
|
||||
when control-statement is the first statement in a buffer (Bug#15956).
|
||||
|
||||
2013-11-24 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* imenu.el (imenu-generic-skip-comments-and-strings):
|
||||
New option (Bug#15560).
|
||||
(imenu--generic-function): Use it.
|
||||
|
||||
2013-11-24 Jorgen Schaefer <contact@jorgenschaefer.de>
|
||||
|
||||
* minibuffer.el (completion--in-region-1): Scroll the correct
|
||||
window. (Bug#13898)
|
||||
|
||||
2013-11-24 Bozhidar Batsov <bozhidar@batsov.com>
|
||||
|
||||
* emacs-lisp/helpers.el: Add some string helpers.
|
||||
(string-trim-left): Removes leading whitespace.
|
||||
(string-trim-right): Removes trailing whitespace.
|
||||
(string-trim): Removes leading and trailing whitespace.
|
||||
|
||||
* subr.el (string-suffix-p): New function.
|
||||
|
||||
2013-11-23 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* progmodes/python.el (python-shell-send-file):
|
||||
Add option to delete file when done. (Bug#15647)
|
||||
(python-shell-send-string, python-shell-send-region): Use it.
|
||||
|
||||
2013-11-23 Ivan Shmakov <ivan@siamics.net> (tiny change)
|
||||
|
||||
* vc/diff-mode.el (diff-mode): Only allow diff-default-read-only
|
||||
to set buffer-read-only to t, never to nil. (Bug#15938)
|
||||
|
||||
* textmodes/tex-mode.el (latex-noindent-environments):
|
||||
Add safe-local-variable property. (Bug#15936)
|
||||
|
||||
2013-11-23 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* textmodes/enriched.el (enriched-mode): Doc fix.
|
||||
* emacs-lisp/authors.el (authors-renamed-files-alist):
|
||||
Add enriched.doc -> enriched.txt.
|
||||
|
||||
* Makefile.in (emacs): Empty EMACSLOADPATH rather than unsetting.
|
||||
|
||||
2013-11-22 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* progmodes/octave.el (inferior-octave-startup): Spit out error
|
||||
message.
|
||||
|
||||
2013-11-22 Bozhidar Batsov <bozhidar@batsov.com>
|
||||
|
||||
* progmodes/ruby-mode.el (ruby-custom-encoding-magic-comment-template):
|
||||
Improve docstring.
|
||||
Add :version.
|
||||
(ruby-encoding-magic-comment-style): Add :version.
|
||||
|
||||
2013-11-22 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* progmodes/octave.el (octave-operator-regexp): Exclude newline.
|
||||
(Bug#15076)
|
||||
(octave-help-mode): Adapt to change to help-mode-finish to use
|
||||
derived-mode-p on 2013-09-17.
|
||||
(inferior-octave-prompt): Also match octave-gui.
|
||||
(octave-kill-process): Don't ask twice. (Bug#10564)
|
||||
|
||||
2013-11-22 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* progmodes/octave.el (inferior-octave-process-live-p): New helper.
|
||||
(inferior-octave-startup, inferior-octave-check-process)
|
||||
(inferior-octave-track-window-width-change)
|
||||
(octave-completion-at-point, octave-eldoc-function): Use it.
|
||||
(octave-kill-process): Provide confirmation. (Bug#10564)
|
||||
|
||||
2013-11-21 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* progmodes/octave.el (octave-mode, inferior-octave-mode):
|
||||
Fix obsolete variable comment-use-global-state.
|
||||
|
||||
2013-11-21 Rüdiger Sonderfeld <ruediger@c-plusplus.de>
|
||||
|
||||
* progmodes/octave.el (octave-mode-map, octave-mode-menu):
|
||||
Add `octave-source-file'.
|
||||
(octave-source-file): New function. (Bug#15935)
|
||||
|
||||
2013-11-21 Kenjiro Nakayama <nakayamakenjiro@gmail.com> (tiny change)
|
||||
|
||||
* net/eww.el (eww-local-regex): New variable.
|
||||
(eww): Use it to detect localhost and similar.
|
||||
|
||||
2013-11-21 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
Add completion for command `ag'.
|
||||
* pcmpl-x.el (pcmpl-x-ag-options): New variable.
|
||||
(pcomplete/ag): New function.
|
||||
(pcmpl-x-ag-options): New function. Handle `[no]' in long options.
|
||||
|
||||
2013-11-21 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* emacs-lisp/byte-run.el (eval-when-compile): Fix edebug spec
|
||||
(bug#14646).
|
||||
(make-obsolete): Remove interactive spec.
|
||||
|
||||
2013-11-21 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* startup.el (command-line-1): Use path-separator with -L.
|
||||
|
||||
2013-11-20 Teodor Zlatanov <tzz@lifelogs.com>
|
||||
|
||||
* emacs-lisp/package.el (describe-package-1): Add package archive
|
||||
to shown fields.
|
||||
|
||||
2013-11-20 Bozhidar Batsov <bozhidar@batsov.com>
|
||||
|
||||
* progmodes/ruby-mode.el (ruby-custom-encoding-magic-comment-template):
|
||||
Change default to "# encoding: %s" to differentiate it from the
|
||||
default Ruby encoding comment template.
|
||||
|
||||
2013-11-20 era eriksson <era+emacsbugs@iki.fi>
|
||||
|
||||
* ses.el (ses-mode): Doc fix. (Bug#14748)
|
||||
|
||||
2013-11-20 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* window.el (display-buffer-alist): Doc fix. (Bug#13594)
|
||||
|
||||
2013-11-19 Dan Nicolaescu <dann@gnu.org>
|
||||
|
||||
* vc/vc-git.el (vc-git-dir-extra-headers): Add headers
|
||||
when rebase or bisect are in progress.
|
||||
|
||||
2013-11-19 Xue Fuqiao <xfq.free@gmail.com>
|
||||
|
||||
* filenotify.el (file-notify-add-watch): Doc fix.
|
||||
|
||||
2013-11-19 Leo Liu <sdl.web@gmail.com>
|
||||
|
||||
* obsolete/rcompile.el: Mark obsolete.
|
||||
|
||||
* progmodes/compile.el (compilation-start)
|
||||
(compilation-goto-locus, compilation-find-file):
|
||||
Pass no-display-ok and handle nil value from display-buffer.
|
||||
(Bug#13594)
|
||||
|
||||
* window.el (display-buffer-alist, display-buffer): Document the
|
||||
new parameter no-display-ok. Return either a window or nil
|
||||
but never a non-window value.
|
||||
|
||||
2013-11-18 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* electric.el (electric-indent-mode-map): Remove.
|
||||
|
@ -84,9 +759,13 @@
|
|||
* subr.el (version-regexp-alist):
|
||||
Recognize hg, svn and darcs versions as snapshot versions.
|
||||
|
||||
* progmodes/ruby-mode.el (ruby-mode-set-encoding):
|
||||
Add the ability to always insert an utf-8 encoding comment.
|
||||
Fix and simplify coding comment update logic.
|
||||
* progmodes/ruby-mode.el (ruby--detect-encoding): Make aware of
|
||||
'always-utf8 value of `ruby-insert-encoding-magic-comment'.
|
||||
(ruby--encoding-comment-required-p): Extract from
|
||||
`ruby-mode-set-encoding'.
|
||||
(ruby-mode-set-encoding): Add the ability to always insert an
|
||||
utf-8 encoding comment. Fix and simplify coding comment update
|
||||
logic.
|
||||
|
||||
2013-11-14 Michael Albinus <michael.albinus@gmx.de>
|
||||
|
||||
|
@ -232,9 +911,13 @@
|
|||
|
||||
2013-11-08 Bozhidar Batsov <bozhidar@batsov.com>
|
||||
|
||||
* progmodes/ruby-mode.el (ruby-mode-set-encoding):
|
||||
Use `ruby-encoding-magic-comment-style' to control the
|
||||
style of the auto-inserted encoding comment.
|
||||
* progmodes/ruby-mode.el: Improve encoding comment handling.
|
||||
(ruby-encoding-magic-comment-style): New option.
|
||||
(ruby-custom-encoding-magic-comment-template): New option.
|
||||
(ruby--insert-coding-comment, ruby--detect-encoding):
|
||||
New functions extracted from `ruby-mode-set-encoding'.
|
||||
(ruby-mode-set-encoding): Use `ruby-encoding-magic-comment-style'
|
||||
to control the style of the auto-inserted encoding comment.
|
||||
|
||||
2013-11-08 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
|
@ -1419,7 +2102,7 @@
|
|||
of GIF DLLs for versions before and after 5.0.0 of giflib.
|
||||
(Bug#15531)
|
||||
|
||||
2013-10-10 João Távora <joaotavora@gmail.com>
|
||||
2013-10-10 João Távora <joaotavora@gmail.com>
|
||||
|
||||
* vc/vc.el (vc-diff-build-argument-list-internal): If the file is
|
||||
not locked, use last revision and current source as
|
||||
|
|
|
@ -3730,7 +3730,8 @@
|
|||
2012-11-19 Daniel Colascione <dancol@dancol.org>
|
||||
|
||||
* term/w32-win.el (cygwin-convert-path-from-windows):
|
||||
Accomodate rename of cygwin_convert_path* to cygwin_convert_file_name*.
|
||||
Accommodate rename of cygwin_convert_path* to
|
||||
cygwin_convert_file_name*.
|
||||
|
||||
2012-11-18 Chong Yidong <cyd@gnu.org>
|
||||
|
||||
|
|
|
@ -106,7 +106,7 @@ COMPILE_FIRST = \
|
|||
|
||||
# The actual Emacs command run in the targets below.
|
||||
# Prevent any setting of EMACSLOADPATH in user environment causing problems.
|
||||
emacs = unset EMACSLOADPATH; "$(EMACS)" $(EMACSOPT)
|
||||
emacs = EMACSLOADPATH= "$(EMACS)" $(EMACSOPT)
|
||||
|
||||
# Common command to find subdirectories
|
||||
setwins=for file in `find . -type d -print`; do \
|
||||
|
@ -118,14 +118,15 @@ setwins=for file in `find . -type d -print`; do \
|
|||
# Find all subdirectories except `obsolete' and `term'.
|
||||
setwins_almost=for file in `find ${srcdir} -type d -print`; do \
|
||||
case $$file in ${srcdir}*/obsolete | ${srcdir}*/term ) ;; \
|
||||
*) wins="$$wins$${wins:+ }$$file" ;; \
|
||||
*) wins="$$wins$${wins:+ }$$file" ;; \
|
||||
esac; \
|
||||
done
|
||||
|
||||
# Find all subdirectories in which we might want to create subdirs.el.
|
||||
setwins_for_subdirs=for file in `find ${srcdir} -type d -print`; do \
|
||||
case $$file in ${srcdir}*/cedet* ) ;; \
|
||||
*) wins="$$wins$${wins:+ }$$file" ;; \
|
||||
case $$file in \
|
||||
${srcdir}*/cedet* | ${srcdir}*/leim* ) ;; \
|
||||
*) wins="$$wins$${wins:+ }$$file" ;; \
|
||||
esac; \
|
||||
done
|
||||
|
||||
|
@ -172,6 +173,10 @@ finder-data: doit
|
|||
# The chmod +w is to handle env var CVSREAD=1.
|
||||
# Use expand-file-name rather than $abs_scrdir so that Emacs does not
|
||||
# get confused when it compares file-names for equality.
|
||||
#
|
||||
# Note that we set no-update-autoloads in _generated_ leim files.
|
||||
# If you want to allow autoloads in such files, remove that,
|
||||
# and make this depend on leim.
|
||||
autoloads: $(LOADDEFS) doit
|
||||
cd $(lisp) && chmod +w $(AUTOGEN_VCS)
|
||||
$(setwins_almost); \
|
||||
|
@ -291,7 +296,7 @@ compile-targets: $(TARGETS)
|
|||
|
||||
# Compile all the Elisp files that need it. Beware: it approximates
|
||||
# `no-byte-compile', so watch out for false-positives!
|
||||
compile-main: compile-clean
|
||||
compile-main: leim semantic compile-clean
|
||||
@(cd $(lisp) && $(setwins); \
|
||||
els=`echo "$$wins " | sed -e 's|/\./|/|g' -e 's|/\. | |g' -e 's| |/*.el |g'`; \
|
||||
for el in $$els; do \
|
||||
|
@ -315,6 +320,18 @@ compile-clean:
|
|||
fi \
|
||||
done
|
||||
|
||||
.PHONY: leim semantic
|
||||
leim:
|
||||
cd ../leim && $(MAKE) $(MFLAGS) all EMACS="$(EMACS)"
|
||||
|
||||
# FIXME. Yuck.
|
||||
semantic:
|
||||
case ${EMACS} in \
|
||||
.*) EMACS="../${EMACS}" ;; \
|
||||
*) EMACS="${EMACS}" ;; \
|
||||
esac; \
|
||||
cd ../admin/grammars && $(MAKE) $(MFLAGS) all EMACS="$${EMACS}"
|
||||
|
||||
# Compile all Lisp files, but don't recompile those that are up to
|
||||
# date. Some .el files don't get compiled because they set the
|
||||
# local variable no-byte-compile.
|
||||
|
|
|
@ -1,3 +1,25 @@
|
|||
2013-11-30 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
Stop keeping (most) generated cedet grammar files in the repository.
|
||||
* semantic/bovine/grammar.el (bovine--make-parser-1):
|
||||
New function, split from bovine-make-parsers.
|
||||
(bovine-make-parsers): Use bovine--make-parser-1.
|
||||
(bovine-batch-make-parser): New function.
|
||||
* semantic/wisent/grammar.el (wisent--make-parser-1):
|
||||
New function, split from wisent-make-parsers.
|
||||
(wisent-make-parsers): Use wisent--make-parser-1.
|
||||
(wisent-batch-make-parser): New function.
|
||||
* semantic/db.el (semanticdb-save-all-db):
|
||||
Avoid prompting in batch mode.
|
||||
* semantic/grammar.el (semantic-grammar-footer-template):
|
||||
Disable version-control and autoloads in the output.
|
||||
(semantic-grammar-create-package):
|
||||
Add option to return nil if output is up-to-date.
|
||||
* semantic/bovine/c-by.el, semantic/bovine/make-by.el:
|
||||
* semantic/bovine/scm-by.el, semantic/wisent/javat-wy.el:
|
||||
* semantic/wisent/js-wy.el, semantic/wisent/python-wy.el:
|
||||
* srecode/srt-wy.el: Remove generated files from repository.
|
||||
|
||||
2013-11-16 Barry O'Reilly <gundaetiapo@gmail.com>
|
||||
|
||||
* semantic/fw.el (semantic-exit-on-input)
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -443,34 +443,39 @@ Menu items are appended to the common grammar menu.")
|
|||
)
|
||||
"Semantic grammar macros used in bovine grammars.")
|
||||
|
||||
(defun bovine-make-parsers ()
|
||||
"Generate Emacs' built-in Bovine-based parser files."
|
||||
(interactive)
|
||||
(semantic-mode 1)
|
||||
;; Loop through each .by file in current directory, and run
|
||||
;; `semantic-grammar-batch-build-one-package' to build the grammar.
|
||||
(dolist (f (directory-files default-directory nil "\\.by\\'"))
|
||||
(let ((packagename
|
||||
(condition-case err
|
||||
(with-current-buffer (find-file-noselect f)
|
||||
(semantic-grammar-create-package))
|
||||
(error (message "%s" (error-message-string err)) nil)))
|
||||
lang filename copyright-end)
|
||||
(when (and packagename
|
||||
(string-match "^.*/\\(.*\\)-by\\.el\\'" packagename))
|
||||
(setq lang (match-string 1 packagename))
|
||||
(setq filename (concat lang "-by.el"))
|
||||
(with-temp-buffer
|
||||
(insert-file-contents filename)
|
||||
(setq buffer-file-name (expand-file-name filename))
|
||||
;; Fix copyright header:
|
||||
(goto-char (point-min))
|
||||
(re-search-forward "^;; Author:")
|
||||
(setq copyright-end (match-beginning 0))
|
||||
(re-search-forward "^;;; Code:\n")
|
||||
(delete-region copyright-end (match-end 0))
|
||||
(goto-char copyright-end)
|
||||
(insert ";; This file is part of GNU Emacs.
|
||||
(defun bovine--make-parser-1 (infile &optional outdir)
|
||||
(if outdir (setq outdir (file-name-directory (expand-file-name outdir))))
|
||||
;; It would be nicer to use a temp-buffer rather than find-file-noselect.
|
||||
;; The only thing stopping us is bovine-grammar-setupcode-builder's
|
||||
;; use of (buffer-name). Perhaps that could be changed to
|
||||
;; (file-name-nondirectory (buffer-file-name)) ?
|
||||
;; (with-temp-buffer
|
||||
;; (insert-file-contents infile)
|
||||
;; (bovine-grammar-mode)
|
||||
;; (setq buffer-file-name (expand-file-name infile))
|
||||
;; (if outdir (setq default-directory outdir))
|
||||
(let ((packagename
|
||||
;; This is with-demoted-errors.
|
||||
(condition-case err
|
||||
(with-current-buffer (find-file-noselect infile)
|
||||
(if outdir (setq default-directory outdir))
|
||||
(semantic-grammar-create-package nil t))
|
||||
(error (message "%s" (error-message-string err)) nil)))
|
||||
lang filename copyright-end)
|
||||
(when (and packagename
|
||||
(string-match "^.*/\\(.*\\)-by\\.el\\'" packagename))
|
||||
(setq lang (match-string 1 packagename))
|
||||
(setq filename (expand-file-name (concat lang "-by.el") outdir))
|
||||
(with-temp-file filename
|
||||
(insert-file-contents filename)
|
||||
;; Fix copyright header:
|
||||
(goto-char (point-min))
|
||||
(re-search-forward "^;; Author:")
|
||||
(setq copyright-end (match-beginning 0))
|
||||
(re-search-forward "^;;; Code:\n")
|
||||
(delete-region copyright-end (match-end 0))
|
||||
(goto-char copyright-end)
|
||||
(insert ";; This file is part of GNU Emacs.
|
||||
|
||||
;; GNU Emacs is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
|
@ -488,18 +493,50 @@ Menu items are appended to the common grammar menu.")
|
|||
;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/"
|
||||
lang ".by.
|
||||
lang ".by.
|
||||
|
||||
;;; Code:
|
||||
")
|
||||
(goto-char (point-min))
|
||||
(delete-region (point-min) (line-end-position))
|
||||
(insert ";;; " packagename
|
||||
" --- Generated parser support file")
|
||||
(delete-trailing-whitespace)
|
||||
(re-search-forward ";;; \\(.*\\) ends here")
|
||||
(replace-match packagename nil nil nil 1)
|
||||
(save-buffer))))))
|
||||
(goto-char (point-min))
|
||||
(delete-region (point-min) (line-end-position))
|
||||
(insert ";;; " packagename
|
||||
" --- Generated parser support file")
|
||||
(delete-trailing-whitespace)
|
||||
(re-search-forward ";;; \\(.*\\) ends here")
|
||||
(replace-match packagename nil nil nil 1)))))
|
||||
|
||||
(defun bovine-make-parsers ()
|
||||
"Generate Emacs's built-in Bovine-based parser files."
|
||||
(interactive)
|
||||
(semantic-mode 1)
|
||||
;; Loop through each .by file in current directory, and run
|
||||
;; `semantic-grammar-batch-build-one-package' to build the grammar.
|
||||
(dolist (f (directory-files default-directory nil "\\.by\\'"))
|
||||
(bovine--make-parser-1 f)))
|
||||
|
||||
|
||||
(defun bovine-batch-make-parser (&optional infile outdir)
|
||||
"Generate a Bovine parser from input INFILE, writing to OUTDIR.
|
||||
This is mainly intended for use in batch mode:
|
||||
|
||||
emacs -batch -l semantic/bovine/grammar -f bovine-make-parser-batch \\
|
||||
[-dir output-dir | -o output-file] file.by
|
||||
|
||||
If -o is supplied, only the directory part is used."
|
||||
(semantic-mode 1)
|
||||
(when (and noninteractive (not infile))
|
||||
(let (arg)
|
||||
(while command-line-args-left
|
||||
(setq arg (pop command-line-args-left))
|
||||
(cond ((string-equal arg "-dir")
|
||||
(setq outdir (pop command-line-args-left)))
|
||||
((string-equal arg "-o")
|
||||
(setq outdir (file-name-directory (pop command-line-args-left))))
|
||||
(t (setq infile arg))))))
|
||||
(or infile (error "No input file specified"))
|
||||
(or (file-readable-p infile)
|
||||
(error "Input file `%s' not readable" infile))
|
||||
(bovine--make-parser-1 infile outdir))
|
||||
|
||||
(provide 'semantic/bovine/grammar)
|
||||
|
||||
|
|
|
@ -1,391 +0,0 @@
|
|||
;;; semantic/bovine/make-by.el --- Generated parser support file
|
||||
|
||||
;; Copyright (C) 1999-2004, 2008-2013 Free Software Foundation, Inc.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
;; GNU Emacs is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
;; the Free Software Foundation, either version 3 of the License, or
|
||||
;; (at your option) any later version.
|
||||
|
||||
;; GNU Emacs is distributed in the hope that it will be useful,
|
||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;; GNU General Public License for more details.
|
||||
|
||||
;; You should have received a copy of the GNU General Public License
|
||||
;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/make.by.
|
||||
|
||||
;;; Code:
|
||||
|
||||
(require 'semantic/lex)
|
||||
(eval-when-compile (require 'semantic/bovine))
|
||||
|
||||
;;; Prologue
|
||||
;;
|
||||
|
||||
;;; Declarations
|
||||
;;
|
||||
(defconst semantic-make-by--keyword-table
|
||||
(semantic-lex-make-keyword-table
|
||||
'(("if" . IF)
|
||||
("ifdef" . IFDEF)
|
||||
("ifndef" . IFNDEF)
|
||||
("ifeq" . IFEQ)
|
||||
("ifneq" . IFNEQ)
|
||||
("else" . ELSE)
|
||||
("endif" . ENDIF)
|
||||
("include" . INCLUDE))
|
||||
'(("include" summary "Macro: include filename1 filename2 ...")
|
||||
("ifneq" summary "Conditional: ifneq (expression) ... else ... endif")
|
||||
("ifeq" summary "Conditional: ifeq (expression) ... else ... endif")
|
||||
("ifndef" summary "Conditional: ifndef (expression) ... else ... endif")
|
||||
("ifdef" summary "Conditional: ifdef (expression) ... else ... endif")
|
||||
("endif" summary "Conditional: if (expression) ... else ... endif")
|
||||
("else" summary "Conditional: if (expression) ... else ... endif")
|
||||
("if" summary "Conditional: if (expression) ... else ... endif")))
|
||||
"Table of language keywords.")
|
||||
|
||||
(defconst semantic-make-by--token-table
|
||||
(semantic-lex-make-type-table
|
||||
'(("punctuation"
|
||||
(BACKSLASH . "\\`[\\]\\'")
|
||||
(DOLLAR . "\\`[$]\\'")
|
||||
(EQUAL . "\\`[=]\\'")
|
||||
(PLUS . "\\`[+]\\'")
|
||||
(COLON . "\\`[:]\\'")))
|
||||
'nil)
|
||||
"Table of lexical tokens.")
|
||||
|
||||
(defconst semantic-make-by--parse-table
|
||||
`(
|
||||
(bovine-toplevel
|
||||
(Makefile)
|
||||
) ;; end bovine-toplevel
|
||||
|
||||
(Makefile
|
||||
(bol
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(bol
|
||||
variable
|
||||
,(semantic-lambda
|
||||
(nth 1 vals))
|
||||
)
|
||||
(bol
|
||||
rule
|
||||
,(semantic-lambda
|
||||
(nth 1 vals))
|
||||
)
|
||||
(bol
|
||||
conditional
|
||||
,(semantic-lambda
|
||||
(nth 1 vals))
|
||||
)
|
||||
(bol
|
||||
include
|
||||
,(semantic-lambda
|
||||
(nth 1 vals))
|
||||
)
|
||||
(whitespace
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
) ;; end Makefile
|
||||
|
||||
(variable
|
||||
(symbol
|
||||
opt-whitespace
|
||||
equals
|
||||
opt-whitespace
|
||||
element-list
|
||||
,(semantic-lambda
|
||||
(semantic-tag-new-variable
|
||||
(nth 0 vals) nil
|
||||
(nth 4 vals)))
|
||||
)
|
||||
) ;; end variable
|
||||
|
||||
(rule
|
||||
(targets
|
||||
opt-whitespace
|
||||
colons
|
||||
opt-whitespace
|
||||
element-list
|
||||
commands
|
||||
,(semantic-lambda
|
||||
(semantic-tag-new-function
|
||||
(nth 0 vals) nil
|
||||
(nth 4 vals)))
|
||||
)
|
||||
) ;; end rule
|
||||
|
||||
(targets
|
||||
(target
|
||||
opt-whitespace
|
||||
targets
|
||||
,(semantic-lambda
|
||||
(list
|
||||
(car
|
||||
(nth 0 vals))
|
||||
(car
|
||||
(nth 2 vals))))
|
||||
)
|
||||
(target
|
||||
,(semantic-lambda
|
||||
(list
|
||||
(car
|
||||
(nth 0 vals))))
|
||||
)
|
||||
) ;; end targets
|
||||
|
||||
(target
|
||||
(sub-target
|
||||
target
|
||||
,(semantic-lambda
|
||||
(list
|
||||
(concat
|
||||
(car
|
||||
(nth 0 vals))
|
||||
(car
|
||||
(nth 2 vals)))))
|
||||
)
|
||||
(sub-target
|
||||
,(semantic-lambda
|
||||
(list
|
||||
(car
|
||||
(nth 0 vals))))
|
||||
)
|
||||
) ;; end target
|
||||
|
||||
(sub-target
|
||||
(symbol)
|
||||
(string)
|
||||
(varref)
|
||||
) ;; end sub-target
|
||||
|
||||
(conditional
|
||||
(IF
|
||||
some-whitespace
|
||||
symbol
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(IFDEF
|
||||
some-whitespace
|
||||
symbol
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(IFNDEF
|
||||
some-whitespace
|
||||
symbol
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(IFEQ
|
||||
some-whitespace
|
||||
expression
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(IFNEQ
|
||||
some-whitespace
|
||||
expression
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(ELSE
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(ENDIF
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
) ;; end conditional
|
||||
|
||||
(expression
|
||||
(semantic-list)
|
||||
) ;; end expression
|
||||
|
||||
(include
|
||||
(INCLUDE
|
||||
some-whitespace
|
||||
element-list
|
||||
,(semantic-lambda
|
||||
(semantic-tag-new-include
|
||||
(nth 2 vals) nil))
|
||||
)
|
||||
) ;; end include
|
||||
|
||||
(equals
|
||||
(punctuation
|
||||
"\\`[:]\\'"
|
||||
punctuation
|
||||
"\\`[=]\\'"
|
||||
,(semantic-lambda)
|
||||
)
|
||||
(punctuation
|
||||
"\\`[+]\\'"
|
||||
punctuation
|
||||
"\\`[=]\\'"
|
||||
,(semantic-lambda)
|
||||
)
|
||||
(punctuation
|
||||
"\\`[=]\\'"
|
||||
,(semantic-lambda)
|
||||
)
|
||||
) ;; end equals
|
||||
|
||||
(colons
|
||||
(punctuation
|
||||
"\\`[:]\\'"
|
||||
punctuation
|
||||
"\\`[:]\\'"
|
||||
,(semantic-lambda)
|
||||
)
|
||||
(punctuation
|
||||
"\\`[:]\\'"
|
||||
,(semantic-lambda)
|
||||
)
|
||||
) ;; end colons
|
||||
|
||||
(element-list
|
||||
(elements
|
||||
newline
|
||||
,(semantic-lambda
|
||||
(nth 0 vals))
|
||||
)
|
||||
) ;; end element-list
|
||||
|
||||
(elements
|
||||
(element
|
||||
some-whitespace
|
||||
elements
|
||||
,(semantic-lambda
|
||||
(nth 0 vals)
|
||||
(nth 2 vals))
|
||||
)
|
||||
(element
|
||||
,(semantic-lambda
|
||||
(nth 0 vals))
|
||||
)
|
||||
( ;;EMPTY
|
||||
)
|
||||
) ;; end elements
|
||||
|
||||
(element
|
||||
(sub-element
|
||||
element
|
||||
,(semantic-lambda
|
||||
(list
|
||||
(concat
|
||||
(car
|
||||
(nth 0 vals))
|
||||
(car
|
||||
(nth 1 vals)))))
|
||||
)
|
||||
( ;;EMPTY
|
||||
)
|
||||
) ;; end element
|
||||
|
||||
(sub-element
|
||||
(symbol)
|
||||
(string)
|
||||
(punctuation)
|
||||
(semantic-list
|
||||
,(semantic-lambda
|
||||
(list
|
||||
(buffer-substring-no-properties
|
||||
(identity start)
|
||||
(identity end))))
|
||||
)
|
||||
) ;; end sub-element
|
||||
|
||||
(varref
|
||||
(punctuation
|
||||
"\\`[$]\\'"
|
||||
semantic-list
|
||||
,(semantic-lambda
|
||||
(list
|
||||
(buffer-substring-no-properties
|
||||
(identity start)
|
||||
(identity end))))
|
||||
)
|
||||
) ;; end varref
|
||||
|
||||
(commands
|
||||
(bol
|
||||
shell-command
|
||||
newline
|
||||
commands
|
||||
,(semantic-lambda
|
||||
(list
|
||||
(nth 0 vals))
|
||||
(nth 1 vals))
|
||||
)
|
||||
( ;;EMPTY
|
||||
,(semantic-lambda)
|
||||
)
|
||||
) ;; end commands
|
||||
|
||||
(opt-whitespace
|
||||
(some-whitespace
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
( ;;EMPTY
|
||||
)
|
||||
) ;; end opt-whitespace
|
||||
|
||||
(some-whitespace
|
||||
(whitespace
|
||||
some-whitespace
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
(whitespace
|
||||
,(semantic-lambda
|
||||
(list nil))
|
||||
)
|
||||
) ;; end some-whitespace
|
||||
)
|
||||
"Parser table.")
|
||||
|
||||
(defun semantic-make-by--install-parser ()
|
||||
"Setup the Semantic Parser."
|
||||
(setq semantic--parse-table semantic-make-by--parse-table
|
||||
semantic-debug-parser-source "make.by"
|
||||
semantic-debug-parser-class 'semantic-bovine-debug-parser
|
||||
semantic-flex-keywords-obarray semantic-make-by--keyword-table
|
||||
))
|
||||
|
||||
|
||||
;;; Analyzers
|
||||
;;
|
||||
|
||||
;;; Epilogue
|
||||
;;
|
||||
|
||||
(provide 'semantic/bovine/make-by)
|
||||
|
||||
;;; semantic/bovine/make-by.el ends here
|
|
@ -1,196 +0,0 @@
|
|||
;;; semantic/bovine/scm-by.el --- Generated parser support file
|
||||
|
||||
;; Copyright (C) 2001, 2003, 2009-2013 Free Software Foundation, Inc.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
;; GNU Emacs is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
;; the Free Software Foundation, either version 3 of the License, or
|
||||
;; (at your option) any later version.
|
||||
|
||||
;; GNU Emacs is distributed in the hope that it will be useful,
|
||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;; GNU General Public License for more details.
|
||||
|
||||
;; You should have received a copy of the GNU General Public License
|
||||
;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/scm.by.
|
||||
|
||||
;;; Code:
|
||||
|
||||
(require 'semantic/lex)
|
||||
(eval-when-compile (require 'semantic/bovine))
|
||||
|
||||
;;; Prologue
|
||||
;;
|
||||
|
||||
;;; Declarations
|
||||
;;
|
||||
(defconst semantic-scm-by--keyword-table
|
||||
(semantic-lex-make-keyword-table
|
||||
'(("define" . DEFINE)
|
||||
("define-module" . DEFINE-MODULE)
|
||||
("load" . LOAD))
|
||||
'(("load" summary "Function: (load \"filename\")")
|
||||
("define-module" summary "Function: (define-module (name arg1 ...)) ")
|
||||
("define" summary "Function: (define symbol expression)")))
|
||||
"Table of language keywords.")
|
||||
|
||||
(defconst semantic-scm-by--token-table
|
||||
(semantic-lex-make-type-table
|
||||
'(("close-paren"
|
||||
(CLOSEPAREN . ")"))
|
||||
("open-paren"
|
||||
(OPENPAREN . "(")))
|
||||
'nil)
|
||||
"Table of lexical tokens.")
|
||||
|
||||
(defconst semantic-scm-by--parse-table
|
||||
`(
|
||||
(bovine-toplevel
|
||||
(scheme)
|
||||
) ;; end bovine-toplevel
|
||||
|
||||
(scheme
|
||||
(semantic-list
|
||||
,(lambda (vals start end)
|
||||
(semantic-bovinate-from-nonterminal
|
||||
(car
|
||||
(nth 0 vals))
|
||||
(cdr
|
||||
(nth 0 vals))
|
||||
'scheme-list))
|
||||
)
|
||||
) ;; end scheme
|
||||
|
||||
(scheme-list
|
||||
(open-paren
|
||||
"("
|
||||
scheme-in-list
|
||||
close-paren
|
||||
")"
|
||||
,(semantic-lambda
|
||||
(nth 1 vals))
|
||||
)
|
||||
) ;; end scheme-list
|
||||
|
||||
(scheme-in-list
|
||||
(DEFINE
|
||||
symbol
|
||||
expression
|
||||
,(semantic-lambda
|
||||
(semantic-tag-new-variable
|
||||
(nth 1 vals) nil
|
||||
(nth 2 vals)))
|
||||
)
|
||||
(DEFINE
|
||||
name-args
|
||||
opt-doc
|
||||
sequence
|
||||
,(semantic-lambda
|
||||
(semantic-tag-new-function
|
||||
(car
|
||||
(nth 1 vals)) nil
|
||||
(cdr
|
||||
(nth 1 vals))))
|
||||
)
|
||||
(DEFINE-MODULE
|
||||
name-args
|
||||
,(semantic-lambda
|
||||
(semantic-tag-new-package
|
||||
(nth
|
||||
(length
|
||||
(nth 1 vals))
|
||||
(nth 1 vals)) nil))
|
||||
)
|
||||
(LOAD
|
||||
string
|
||||
,(semantic-lambda
|
||||
(semantic-tag-new-include
|
||||
(file-name-nondirectory
|
||||
(read
|
||||
(nth 1 vals)))
|
||||
(read
|
||||
(nth 1 vals))))
|
||||
)
|
||||
(symbol
|
||||
,(semantic-lambda
|
||||
(semantic-tag-new-code
|
||||
(nth 0 vals) nil))
|
||||
)
|
||||
) ;; end scheme-in-list
|
||||
|
||||
(name-args
|
||||
(semantic-list
|
||||
,(lambda (vals start end)
|
||||
(semantic-bovinate-from-nonterminal
|
||||
(car
|
||||
(nth 0 vals))
|
||||
(cdr
|
||||
(nth 0 vals))
|
||||
'name-arg-expand))
|
||||
)
|
||||
) ;; end name-args
|
||||
|
||||
(name-arg-expand
|
||||
(open-paren
|
||||
name-arg-expand
|
||||
,(semantic-lambda
|
||||
(nth 1 vals))
|
||||
)
|
||||
(symbol
|
||||
name-arg-expand
|
||||
,(semantic-lambda
|
||||
(cons
|
||||
(nth 0 vals)
|
||||
(nth 1 vals)))
|
||||
)
|
||||
( ;;EMPTY
|
||||
,(semantic-lambda)
|
||||
)
|
||||
) ;; end name-arg-expand
|
||||
|
||||
(opt-doc
|
||||
(string)
|
||||
( ;;EMPTY
|
||||
)
|
||||
) ;; end opt-doc
|
||||
|
||||
(sequence
|
||||
(expression
|
||||
sequence)
|
||||
(expression)
|
||||
) ;; end sequence
|
||||
|
||||
(expression
|
||||
(symbol)
|
||||
(semantic-list)
|
||||
(string)
|
||||
(number)
|
||||
) ;; end expression
|
||||
)
|
||||
"Parser table.")
|
||||
|
||||
(defun semantic-scm-by--install-parser ()
|
||||
"Setup the Semantic Parser."
|
||||
(setq semantic--parse-table semantic-scm-by--parse-table
|
||||
semantic-debug-parser-source "scheme.by"
|
||||
semantic-debug-parser-class 'semantic-bovine-debug-parser
|
||||
semantic-flex-keywords-obarray semantic-scm-by--keyword-table
|
||||
))
|
||||
|
||||
|
||||
;;; Analyzers
|
||||
;;
|
||||
|
||||
;;; Epilogue
|
||||
;;
|
||||
|
||||
(provide 'semantic/bovine/scm-by)
|
||||
|
||||
;;; semantic/bovine/scm-by.el ends here
|
|
@ -697,7 +697,7 @@ form."
|
|||
(interactive)
|
||||
(unless noninteractive
|
||||
(message "Saving tag summaries..."))
|
||||
(let ((semanticdb--inhibit-make-directory nil))
|
||||
(let ((semanticdb--inhibit-make-directory noninteractive))
|
||||
(mapc 'semanticdb-save-db semanticdb-database-list))
|
||||
(unless noninteractive
|
||||
(message "Saving tag summaries...done")))
|
||||
|
|
|
@ -33,6 +33,8 @@
|
|||
(require 'semantic/wisent)
|
||||
(require 'semantic/ctxt)
|
||||
(require 'semantic/format)
|
||||
;; FIXME this is a generated file, but we need to load this file to
|
||||
;; generate it!
|
||||
(require 'semantic/grammar-wy)
|
||||
(require 'semantic/idle)
|
||||
(require 'help-fns)
|
||||
|
@ -605,6 +607,11 @@ The symbols in the template are local variables in
|
|||
|
||||
\(provide '" libr ")
|
||||
|
||||
;; Local Variables:
|
||||
;; version-control: never
|
||||
;; no-update-autoloads: t
|
||||
;; End:
|
||||
|
||||
;;; " file " ends here
|
||||
")
|
||||
"Generated footer template.
|
||||
|
@ -822,9 +829,10 @@ Block definitions are read from the current table of lexical types."
|
|||
(noninteractive)
|
||||
noninteractive))
|
||||
|
||||
(defun semantic-grammar-create-package (&optional force)
|
||||
(defun semantic-grammar-create-package (&optional force uptodate)
|
||||
"Create package Lisp code from grammar in current buffer.
|
||||
Does nothing if the Lisp code seems up to date.
|
||||
If the Lisp code seems up to date, do nothing (if UPTODATE
|
||||
is non-nil, return nil in such cases).
|
||||
If optional argument FORCE is non-nil, unconditionally re-generate the
|
||||
Lisp code."
|
||||
(interactive "P")
|
||||
|
@ -854,7 +862,12 @@ Lisp code."
|
|||
(file-newer-than-file-p
|
||||
(buffer-file-name semantic--grammar-output-buffer)
|
||||
(buffer-file-name semantic--grammar-input-buffer)))
|
||||
(message "Package `%s' is up to date." semantic--grammar-package)
|
||||
(progn
|
||||
(message "Package `%s' is up to date." semantic--grammar-package)
|
||||
;; It would be better if this were always the case, IMO,
|
||||
;; but the (unspecified) return value of this function is
|
||||
;; assumed to be non-nil in some places, it seems.
|
||||
(if uptodate (setq output nil)))
|
||||
;; Create the package
|
||||
(set-buffer semantic--grammar-output-buffer)
|
||||
;; Use Unix EOLs, so that the file is portable to all platforms.
|
||||
|
@ -1914,6 +1927,7 @@ Optional argument COLOR determines if color is added to the text."
|
|||
|
||||
(provide 'semantic/grammar)
|
||||
|
||||
|
||||
;; Local variables:
|
||||
;; generated-autoload-load-name: "semantic/grammar"
|
||||
;; End:
|
||||
|
|
|
@ -473,6 +473,54 @@ Menu items are appended to the common grammar menu.")
|
|||
\;; 2009, 2010 Python Software Foundation; All Rights Reserved"
|
||||
,wisent-make-parsers--python-license)))
|
||||
|
||||
;; Cf bovine--make-parser-1.
|
||||
(defun wisent--make-parser-1 (infile &optional outdir)
|
||||
(if outdir (setq outdir (file-name-directory (expand-file-name outdir))))
|
||||
(let ((packagename
|
||||
;; This is with-demoted-errors.
|
||||
(condition-case err
|
||||
(with-current-buffer (find-file-noselect infile)
|
||||
(if outdir (setq default-directory outdir))
|
||||
(semantic-grammar-create-package nil t))
|
||||
(error (message "%s" (error-message-string err)) nil)))
|
||||
output-data)
|
||||
(when (setq output-data (assoc packagename wisent-make-parsers--parser-file-name))
|
||||
(let ((additional-copyright (nth 1 output-data))
|
||||
(additional-license (nth 2 output-data))
|
||||
(filename (expand-file-name
|
||||
(progn (string-match ".*/\\(.*\\)" packagename)
|
||||
(match-string 1 packagename))
|
||||
outdir))
|
||||
copyright-end)
|
||||
;; Touch up the generated parsers for Emacs integration.
|
||||
(with-temp-file filename
|
||||
(insert-file-contents filename)
|
||||
;; Fix copyright header:
|
||||
(goto-char (point-min))
|
||||
(when additional-copyright
|
||||
(re-search-forward "Copyright (C).*$")
|
||||
(insert "\n;; " additional-copyright))
|
||||
(re-search-forward "^;; Author:")
|
||||
(setq copyright-end (match-beginning 0))
|
||||
(re-search-forward "^;;; Code:\n")
|
||||
(delete-region copyright-end (match-end 0))
|
||||
(goto-char copyright-end)
|
||||
(insert wisent-make-parsers--emacs-license)
|
||||
(insert "\n\n;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/"
|
||||
(file-name-nondirectory infile) ".")
|
||||
(when additional-license
|
||||
(insert "\n" additional-license))
|
||||
(insert "\n\n;;; Code:\n")
|
||||
(goto-char (point-min))
|
||||
(delete-region (point-min) (line-end-position))
|
||||
(insert ";;; " packagename
|
||||
" --- Generated parser support file")
|
||||
(re-search-forward ";;; \\(.*\\) ends here")
|
||||
(replace-match packagename nil nil nil 1)
|
||||
(delete-trailing-whitespace))))))
|
||||
|
||||
(defun wisent-make-parsers ()
|
||||
"Generate Emacs' built-in Wisent-based parser files."
|
||||
(interactive)
|
||||
|
@ -480,46 +528,32 @@ Menu items are appended to the common grammar menu.")
|
|||
;; Loop through each .wy file in current directory, and run
|
||||
;; `semantic-grammar-batch-build-one-package' to build the grammar.
|
||||
(dolist (f (directory-files default-directory nil "\\.wy\\'"))
|
||||
(let ((packagename
|
||||
(condition-case err
|
||||
(with-current-buffer (find-file-noselect f)
|
||||
(semantic-grammar-create-package))
|
||||
(error (message "%s" (error-message-string err)) nil)))
|
||||
output-data)
|
||||
(when (setq output-data (assoc packagename wisent-make-parsers--parser-file-name))
|
||||
(let ((additional-copyright (nth 1 output-data))
|
||||
(additional-license (nth 2 output-data))
|
||||
(filename (progn (string-match ".*/\\(.*\\)" packagename) (match-string 1 packagename)))
|
||||
copyright-end)
|
||||
;; Touch up the generated parsers for Emacs integration.
|
||||
(with-temp-buffer
|
||||
(insert-file-contents filename)
|
||||
;; Fix copyright header:
|
||||
(goto-char (point-min))
|
||||
(when additional-copyright
|
||||
(re-search-forward "Copyright (C).*$")
|
||||
(insert "\n;; " additional-copyright))
|
||||
(re-search-forward "^;; Author:")
|
||||
(setq copyright-end (match-beginning 0))
|
||||
(re-search-forward "^;;; Code:\n")
|
||||
(delete-region copyright-end (match-end 0))
|
||||
(goto-char copyright-end)
|
||||
(insert wisent-make-parsers--emacs-license)
|
||||
(insert "\n\n;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/"
|
||||
f ".")
|
||||
(when additional-license
|
||||
(insert "\n" additional-license))
|
||||
(insert "\n\n;;; Code:\n")
|
||||
(goto-char (point-min))
|
||||
(delete-region (point-min) (line-end-position))
|
||||
(insert ";;; " packagename
|
||||
" --- Generated parser support file")
|
||||
(re-search-forward ";;; \\(.*\\) ends here")
|
||||
(replace-match packagename nil nil nil 1)
|
||||
(delete-trailing-whitespace)
|
||||
(write-region nil nil (expand-file-name filename))))))))
|
||||
(wisent--make-parser-1 f)))
|
||||
|
||||
|
||||
(defun wisent-batch-make-parser (&optional infile outdir)
|
||||
"Generate a Wisent parser from input INFILE, writing to OUTDIR.
|
||||
This is mainly intended for use in batch mode:
|
||||
|
||||
emacs -batch -l semantic/wisent/grammar -f wisent-make-parser-batch \\
|
||||
[-dir output-dir | -o output-file] file.by
|
||||
|
||||
If -o is supplied, only the directory part is used."
|
||||
(semantic-mode 1)
|
||||
(when (and noninteractive (not infile))
|
||||
(let (arg)
|
||||
(while command-line-args-left
|
||||
(setq arg (pop command-line-args-left))
|
||||
(cond ((string-equal arg "-dir")
|
||||
(setq outdir (pop command-line-args-left)))
|
||||
((string-equal arg "-o")
|
||||
(setq outdir (file-name-directory (pop command-line-args-left))))
|
||||
(t (setq infile arg))))))
|
||||
(or infile (error "No input file specified"))
|
||||
(or (file-readable-p infile)
|
||||
(error "Input file `%s' not readable" infile))
|
||||
(wisent--make-parser-1 infile outdir))
|
||||
|
||||
|
||||
(provide 'semantic/wisent/grammar)
|
||||
|
||||
|
|
|
@ -1,688 +0,0 @@
|
|||
;;; semantic/wisent/javat-wy.el --- Generated parser support file
|
||||
|
||||
;; Copyright (C) 2002-2013 Free Software Foundation, Inc.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
;; GNU Emacs is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
;; the Free Software Foundation, either version 3 of the License, or
|
||||
;; (at your option) any later version.
|
||||
|
||||
;; GNU Emacs is distributed in the hope that it will be useful,
|
||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;; GNU General Public License for more details.
|
||||
|
||||
;; You should have received a copy of the GNU General Public License
|
||||
;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/java-tags.wy.
|
||||
|
||||
;;; Code:
|
||||
|
||||
(require 'semantic/lex)
|
||||
(eval-when-compile (require 'semantic/bovine))
|
||||
|
||||
;;; Prologue
|
||||
;;
|
||||
(declare-function semantic-parse-region "semantic"
|
||||
(start end &optional nonterminal depth returnonerror))
|
||||
|
||||
;;; Declarations
|
||||
;;
|
||||
(defconst wisent-java-tags-wy--keyword-table
|
||||
(semantic-lex-make-keyword-table
|
||||
'(("abstract" . ABSTRACT)
|
||||
("boolean" . BOOLEAN)
|
||||
("break" . BREAK)
|
||||
("byte" . BYTE)
|
||||
("case" . CASE)
|
||||
("catch" . CATCH)
|
||||
("char" . CHAR)
|
||||
("class" . CLASS)
|
||||
("const" . CONST)
|
||||
("continue" . CONTINUE)
|
||||
("default" . DEFAULT)
|
||||
("do" . DO)
|
||||
("double" . DOUBLE)
|
||||
("else" . ELSE)
|
||||
("extends" . EXTENDS)
|
||||
("final" . FINAL)
|
||||
("finally" . FINALLY)
|
||||
("float" . FLOAT)
|
||||
("for" . FOR)
|
||||
("goto" . GOTO)
|
||||
("if" . IF)
|
||||
("implements" . IMPLEMENTS)
|
||||
("import" . IMPORT)
|
||||
("instanceof" . INSTANCEOF)
|
||||
("int" . INT)
|
||||
("interface" . INTERFACE)
|
||||
("long" . LONG)
|
||||
("native" . NATIVE)
|
||||
("new" . NEW)
|
||||
("package" . PACKAGE)
|
||||
("private" . PRIVATE)
|
||||
("protected" . PROTECTED)
|
||||
("public" . PUBLIC)
|
||||
("return" . RETURN)
|
||||
("short" . SHORT)
|
||||
("static" . STATIC)
|
||||
("strictfp" . STRICTFP)
|
||||
("super" . SUPER)
|
||||
("switch" . SWITCH)
|
||||
("synchronized" . SYNCHRONIZED)
|
||||
("this" . THIS)
|
||||
("throw" . THROW)
|
||||
("throws" . THROWS)
|
||||
("transient" . TRANSIENT)
|
||||
("try" . TRY)
|
||||
("void" . VOID)
|
||||
("volatile" . VOLATILE)
|
||||
("while" . WHILE)
|
||||
("@author" . _AUTHOR)
|
||||
("@version" . _VERSION)
|
||||
("@param" . _PARAM)
|
||||
("@return" . _RETURN)
|
||||
("@exception" . _EXCEPTION)
|
||||
("@throws" . _THROWS)
|
||||
("@see" . _SEE)
|
||||
("@since" . _SINCE)
|
||||
("@serial" . _SERIAL)
|
||||
("@serialData" . _SERIALDATA)
|
||||
("@serialField" . _SERIALFIELD)
|
||||
("@deprecated" . _DEPRECATED))
|
||||
'(("@deprecated" javadoc
|
||||
(seq 12 usage
|
||||
(type function variable)
|
||||
opt t))
|
||||
("@serialField" javadoc
|
||||
(seq 11 usage
|
||||
(variable)
|
||||
opt t))
|
||||
("@serialData" javadoc
|
||||
(seq 10 usage
|
||||
(function)
|
||||
opt t))
|
||||
("@serial" javadoc
|
||||
(seq 9 usage
|
||||
(variable)
|
||||
opt t))
|
||||
("@since" javadoc
|
||||
(seq 8 usage
|
||||
(type function variable)
|
||||
opt t))
|
||||
("@see" javadoc
|
||||
(seq 7 usage
|
||||
(type function variable)
|
||||
opt t with-ref t))
|
||||
("@throws" javadoc
|
||||
(seq 6 usage
|
||||
(function)
|
||||
with-name t))
|
||||
("@exception" javadoc
|
||||
(seq 5 usage
|
||||
(function)
|
||||
with-name t))
|
||||
("@return" javadoc
|
||||
(seq 4 usage
|
||||
(function)))
|
||||
("@param" javadoc
|
||||
(seq 3 usage
|
||||
(function)
|
||||
with-name t))
|
||||
("@version" javadoc
|
||||
(seq 2 usage
|
||||
(type)))
|
||||
("@author" javadoc
|
||||
(seq 1 usage
|
||||
(type)))
|
||||
("while" summary "while (<expr>) <stmt> | do <stmt> while (<expr>);")
|
||||
("volatile" summary "Field declaration modifier: volatile <type> <name> ...")
|
||||
("void" summary "Method return type: void <name> ...")
|
||||
("try" summary "try {<stmts>} [catch(<parm>) {<stmts>} ...] [finally {<stmts>}]")
|
||||
("transient" summary "Field declaration modifier: transient <type> <name> ...")
|
||||
("throws" summary "Method|Constructor declaration: throws <classType>, ...")
|
||||
("throw" summary "throw <expr> ;")
|
||||
("synchronized" summary "synchronized (<expr>) ... | Method decl. modifier: synchronized <type> <name> ...")
|
||||
("switch" summary "switch(<expr>) {[case <const-expr>: <stmts> ...] [default: <stmts>]}")
|
||||
("strictfp" summary "Declaration modifier: strictfp {class|interface|<type>} <name> ...")
|
||||
("static" summary "Declaration modifier: static {class|interface|<type>} <name> ...")
|
||||
("short" summary "Integral primitive type (-32768 to 32767)")
|
||||
("return" summary "return [<expr>] ;")
|
||||
("public" summary "Access level modifier: public {class|interface|<type>} <name> ...")
|
||||
("protected" summary "Access level modifier: protected {class|interface|<type>} <name> ...")
|
||||
("private" summary "Access level modifier: private {class|interface|<type>} <name> ...")
|
||||
("package" summary "Package declaration: package <name>")
|
||||
("native" summary "Method declaration modifier: native <type> <name> ...")
|
||||
("long" summary "Integral primitive type (-9223372036854775808 to 9223372036854775807)")
|
||||
("interface" summary "Interface declaration: interface <name>")
|
||||
("int" summary "Integral primitive type (-2147483648 to 2147483647)")
|
||||
("import" summary "Import package declarations: import <package>")
|
||||
("implements" summary "Class SuperInterfaces declaration: implements <name> [, ...]")
|
||||
("if" summary "if (<expr>) <stmt> [else <stmt>]")
|
||||
("goto" summary "Unused reserved word")
|
||||
("for" summary "for ([<init-expr>]; [<expr>]; [<update-expr>]) <stmt>")
|
||||
("float" summary "Primitive floating-point type (single-precision 32-bit IEEE 754)")
|
||||
("finally" summary "try {<stmts>} ... finally {<stmts>}")
|
||||
("final" summary "Class|Member declaration modifier: final {class|<type>} <name> ...")
|
||||
("extends" summary "SuperClass|SuperInterfaces declaration: extends <name> [, ...]")
|
||||
("else" summary "if (<expr>) <stmt> else <stmt>")
|
||||
("double" summary "Primitive floating-point type (double-precision 64-bit IEEE 754)")
|
||||
("do" summary "do <stmt> while (<expr>);")
|
||||
("default" summary "switch(<expr>) { ... default: <stmts>}")
|
||||
("continue" summary "continue [<label>] ;")
|
||||
("const" summary "Unused reserved word")
|
||||
("class" summary "Class declaration: class <name>")
|
||||
("char" summary "Integral primitive type (0 to 65535)")
|
||||
("catch" summary "try {<stmts>} catch(<parm>) {<stmts>} ... ")
|
||||
("case" summary "switch(<expr>) {case <const-expr>: <stmts> ... }")
|
||||
("byte" summary "Integral primitive type (-128 to 127)")
|
||||
("break" summary "break [<label>] ;")
|
||||
("boolean" summary "Primitive logical quantity type (true or false)")
|
||||
("abstract" summary "Class|Method declaration modifier: abstract {class|<type>} <name> ...")))
|
||||
"Table of language keywords.")
|
||||
|
||||
(defconst wisent-java-tags-wy--token-table
|
||||
(semantic-lex-make-type-table
|
||||
'(("unicode"
|
||||
(unicodecharacter))
|
||||
("number"
|
||||
(NUMBER_LITERAL))
|
||||
("string"
|
||||
(STRING_LITERAL))
|
||||
("symbol"
|
||||
(IDENTIFIER))
|
||||
("punctuation"
|
||||
(COMP . "~")
|
||||
(OROR . "||")
|
||||
(OREQ . "|=")
|
||||
(OR . "|")
|
||||
(XOREQ . "^=")
|
||||
(XOR . "^")
|
||||
(QUESTION . "?")
|
||||
(URSHIFTEQ . ">>>=")
|
||||
(URSHIFT . ">>>")
|
||||
(RSHIFTEQ . ">>=")
|
||||
(RSHIFT . ">>")
|
||||
(GTEQ . ">=")
|
||||
(GT . ">")
|
||||
(EQEQ . "==")
|
||||
(EQ . "=")
|
||||
(LTEQ . "<=")
|
||||
(LSHIFTEQ . "<<=")
|
||||
(LSHIFT . "<<")
|
||||
(LT . "<")
|
||||
(SEMICOLON . ";")
|
||||
(COLON . ":")
|
||||
(DIVEQ . "/=")
|
||||
(DIV . "/")
|
||||
(DOT . ".")
|
||||
(MINUSEQ . "-=")
|
||||
(MINUSMINUS . "--")
|
||||
(MINUS . "-")
|
||||
(COMMA . ",")
|
||||
(PLUSEQ . "+=")
|
||||
(PLUSPLUS . "++")
|
||||
(PLUS . "+")
|
||||
(MULTEQ . "*=")
|
||||
(MULT . "*")
|
||||
(ANDEQ . "&=")
|
||||
(ANDAND . "&&")
|
||||
(AND . "&")
|
||||
(MODEQ . "%=")
|
||||
(MOD . "%")
|
||||
(NOTEQ . "!=")
|
||||
(NOT . "!"))
|
||||
("close-paren"
|
||||
(RBRACK . "]")
|
||||
(RBRACE . "}")
|
||||
(RPAREN . ")"))
|
||||
("open-paren"
|
||||
(LBRACK . "[")
|
||||
(LBRACE . "{")
|
||||
(LPAREN . "("))
|
||||
("block"
|
||||
(BRACK_BLOCK . "(LBRACK RBRACK)")
|
||||
(BRACE_BLOCK . "(LBRACE RBRACE)")
|
||||
(PAREN_BLOCK . "(LPAREN RPAREN)")))
|
||||
'(("keyword" :declared t)
|
||||
("unicode" syntax "\\\\u[0-9a-f][0-9a-f][0-9a-f][0-9a-f]")
|
||||
("unicode" :declared t)
|
||||
("number" :declared t)
|
||||
("string" :declared t)
|
||||
("symbol" :declared t)
|
||||
("punctuation" :declared t)
|
||||
("block" :declared t)))
|
||||
"Table of lexical tokens.")
|
||||
|
||||
(defconst wisent-java-tags-wy--parse-table
|
||||
(progn
|
||||
(eval-when-compile
|
||||
(require 'semantic/wisent/comp))
|
||||
(wisent-compile-grammar
|
||||
'((PAREN_BLOCK BRACE_BLOCK BRACK_BLOCK LPAREN RPAREN LBRACE RBRACE LBRACK RBRACK NOT NOTEQ MOD MODEQ AND ANDAND ANDEQ MULT MULTEQ PLUS PLUSPLUS PLUSEQ COMMA MINUS MINUSMINUS MINUSEQ DOT DIV DIVEQ COLON SEMICOLON LT LSHIFT LSHIFTEQ LTEQ EQ EQEQ GT GTEQ RSHIFT RSHIFTEQ URSHIFT URSHIFTEQ QUESTION XOR XOREQ OR OREQ OROR COMP IDENTIFIER STRING_LITERAL NUMBER_LITERAL unicodecharacter ABSTRACT BOOLEAN BREAK BYTE CASE CATCH CHAR CLASS CONST CONTINUE DEFAULT DO DOUBLE ELSE EXTENDS FINAL FINALLY FLOAT FOR GOTO IF IMPLEMENTS IMPORT INSTANCEOF INT INTERFACE LONG NATIVE NEW PACKAGE PRIVATE PROTECTED PUBLIC RETURN SHORT STATIC STRICTFP SUPER SWITCH SYNCHRONIZED THIS THROW THROWS TRANSIENT TRY VOID VOLATILE WHILE _AUTHOR _VERSION _PARAM _RETURN _EXCEPTION _THROWS _SEE _SINCE _SERIAL _SERIALDATA _SERIALFIELD _DEPRECATED)
|
||||
nil
|
||||
(compilation_unit
|
||||
((package_declaration))
|
||||
((import_declaration))
|
||||
((type_declaration)))
|
||||
(package_declaration
|
||||
((PACKAGE qualified_name SEMICOLON)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-package $2 nil))))
|
||||
(import_declaration
|
||||
((IMPORT qualified_name SEMICOLON)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-include $2 nil)))
|
||||
((IMPORT qualified_name DOT MULT SEMICOLON)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-include
|
||||
(concat $2 $3 $4)
|
||||
nil))))
|
||||
(type_declaration
|
||||
((SEMICOLON)
|
||||
nil)
|
||||
((class_declaration))
|
||||
((interface_declaration)))
|
||||
(class_declaration
|
||||
((modifiers_opt CLASS qualified_name superc_opt interfaces_opt class_body)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-type $3 $2 $6
|
||||
(if
|
||||
(or $4 $5)
|
||||
(cons $4 $5))
|
||||
:typemodifiers $1))))
|
||||
(superc_opt
|
||||
(nil)
|
||||
((EXTENDS qualified_name)
|
||||
(identity $2)))
|
||||
(interfaces_opt
|
||||
(nil)
|
||||
((IMPLEMENTS qualified_name_list)
|
||||
(nreverse $2)))
|
||||
(class_body
|
||||
((BRACE_BLOCK)
|
||||
(semantic-parse-region
|
||||
(car $region1)
|
||||
(cdr $region1)
|
||||
'class_member_declaration 1)))
|
||||
(class_member_declaration
|
||||
((LBRACE)
|
||||
nil)
|
||||
((RBRACE)
|
||||
nil)
|
||||
((block)
|
||||
nil)
|
||||
((static_initializer)
|
||||
nil)
|
||||
((constructor_declaration))
|
||||
((interface_declaration))
|
||||
((class_declaration))
|
||||
((method_declaration))
|
||||
((field_declaration)))
|
||||
(interface_declaration
|
||||
((modifiers_opt INTERFACE qualified_name extends_interfaces_opt interface_body)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-type $3 $2 $5
|
||||
(if $4
|
||||
(cons nil $4))
|
||||
:typemodifiers $1))))
|
||||
(extends_interfaces_opt
|
||||
(nil)
|
||||
((EXTENDS qualified_name_list)
|
||||
(identity $2)))
|
||||
(interface_body
|
||||
((BRACE_BLOCK)
|
||||
(semantic-parse-region
|
||||
(car $region1)
|
||||
(cdr $region1)
|
||||
'interface_member_declaration 1)))
|
||||
(interface_member_declaration
|
||||
((LBRACE)
|
||||
nil)
|
||||
((RBRACE)
|
||||
nil)
|
||||
((interface_declaration))
|
||||
((class_declaration))
|
||||
((method_declaration))
|
||||
((field_declaration)))
|
||||
(static_initializer
|
||||
((STATIC block)))
|
||||
(constructor_declaration
|
||||
((modifiers_opt constructor_declarator throwsc_opt constructor_body)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-function
|
||||
(car $2)
|
||||
nil
|
||||
(cdr $2)
|
||||
:typemodifiers $1 :throws $3 :constructor-flag t))))
|
||||
(constructor_declarator
|
||||
((IDENTIFIER formal_parameter_list)
|
||||
(cons $1 $2)))
|
||||
(constructor_body
|
||||
((block)))
|
||||
(method_declaration
|
||||
((modifiers_opt VOID method_declarator throwsc_opt method_body)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-function
|
||||
(car $3)
|
||||
$2
|
||||
(cdr $3)
|
||||
:typemodifiers $1 :throws $4)))
|
||||
((modifiers_opt type method_declarator throwsc_opt method_body)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-function
|
||||
(car $3)
|
||||
$2
|
||||
(cdr $3)
|
||||
:typemodifiers $1 :throws $4))))
|
||||
(method_declarator
|
||||
((IDENTIFIER formal_parameter_list dims_opt)
|
||||
(cons
|
||||
(concat $1 $3)
|
||||
$2)))
|
||||
(throwsc_opt
|
||||
(nil)
|
||||
((THROWS qualified_name_list)
|
||||
(nreverse $2)))
|
||||
(qualified_name_list
|
||||
((qualified_name_list COMMA qualified_name)
|
||||
(cons $3 $1))
|
||||
((qualified_name)
|
||||
(list $1)))
|
||||
(method_body
|
||||
((SEMICOLON))
|
||||
((block)))
|
||||
(block
|
||||
((BRACE_BLOCK)))
|
||||
(formal_parameter_list
|
||||
((PAREN_BLOCK)
|
||||
(semantic-parse-region
|
||||
(car $region1)
|
||||
(cdr $region1)
|
||||
'formal_parameters 1)))
|
||||
(formal_parameters
|
||||
((LPAREN)
|
||||
nil)
|
||||
((RPAREN)
|
||||
nil)
|
||||
((formal_parameter COMMA))
|
||||
((formal_parameter RPAREN)))
|
||||
(formal_parameter
|
||||
((formal_parameter_modifier_opt type opt_variable_declarator_id)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $3 $2 nil :typemodifiers $1))))
|
||||
(formal_parameter_modifier_opt
|
||||
(nil)
|
||||
((FINAL)
|
||||
(list $1)))
|
||||
(field_declaration
|
||||
((modifiers_opt type variable_declarators SEMICOLON)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $3 $2 nil :typemodifiers $1))))
|
||||
(variable_declarators
|
||||
((variable_declarators COMMA variable_declarator)
|
||||
(progn
|
||||
(setcdr
|
||||
(cdr
|
||||
(car $1))
|
||||
(cdr $region2))
|
||||
(cons $3 $1)))
|
||||
((variable_declarator)
|
||||
(list $1)))
|
||||
(variable_declarator
|
||||
((variable_declarator_id EQ variable_initializer)
|
||||
(cons $1 $region))
|
||||
((variable_declarator_id)
|
||||
(cons $1 $region)))
|
||||
(opt_variable_declarator_id
|
||||
(nil
|
||||
(identity ""))
|
||||
((variable_declarator_id)
|
||||
(identity $1)))
|
||||
(variable_declarator_id
|
||||
((IDENTIFIER dims_opt)
|
||||
(concat $1 $2)))
|
||||
(variable_initializer
|
||||
((expression)))
|
||||
(expression
|
||||
((expression term))
|
||||
((term)))
|
||||
(term
|
||||
((literal))
|
||||
((operator))
|
||||
((primitive_type))
|
||||
((IDENTIFIER))
|
||||
((BRACK_BLOCK))
|
||||
((PAREN_BLOCK))
|
||||
((BRACE_BLOCK))
|
||||
((NEW))
|
||||
((CLASS))
|
||||
((THIS))
|
||||
((SUPER)))
|
||||
(literal
|
||||
((STRING_LITERAL))
|
||||
((NUMBER_LITERAL)))
|
||||
(operator
|
||||
((NOT))
|
||||
((PLUS))
|
||||
((PLUSPLUS))
|
||||
((MINUS))
|
||||
((MINUSMINUS))
|
||||
((NOTEQ))
|
||||
((MOD))
|
||||
((MODEQ))
|
||||
((AND))
|
||||
((ANDAND))
|
||||
((ANDEQ))
|
||||
((MULT))
|
||||
((MULTEQ))
|
||||
((PLUSEQ))
|
||||
((MINUSEQ))
|
||||
((DOT))
|
||||
((DIV))
|
||||
((DIVEQ))
|
||||
((COLON))
|
||||
((LT))
|
||||
((LSHIFT))
|
||||
((LSHIFTEQ))
|
||||
((LTEQ))
|
||||
((EQ))
|
||||
((EQEQ))
|
||||
((GT))
|
||||
((GTEQ))
|
||||
((RSHIFT))
|
||||
((RSHIFTEQ))
|
||||
((URSHIFT))
|
||||
((URSHIFTEQ))
|
||||
((QUESTION))
|
||||
((XOR))
|
||||
((XOREQ))
|
||||
((OR))
|
||||
((OREQ))
|
||||
((OROR))
|
||||
((COMP))
|
||||
((INSTANCEOF)))
|
||||
(primitive_type
|
||||
((BOOLEAN))
|
||||
((CHAR))
|
||||
((LONG))
|
||||
((INT))
|
||||
((SHORT))
|
||||
((BYTE))
|
||||
((DOUBLE))
|
||||
((FLOAT)))
|
||||
(modifiers_opt
|
||||
(nil)
|
||||
((modifiers)
|
||||
(nreverse $1)))
|
||||
(modifiers
|
||||
((modifiers modifier)
|
||||
(cons $2 $1))
|
||||
((modifier)
|
||||
(list $1)))
|
||||
(modifier
|
||||
((STRICTFP))
|
||||
((VOLATILE))
|
||||
((TRANSIENT))
|
||||
((SYNCHRONIZED))
|
||||
((NATIVE))
|
||||
((FINAL))
|
||||
((ABSTRACT))
|
||||
((STATIC))
|
||||
((PRIVATE))
|
||||
((PROTECTED))
|
||||
((PUBLIC)))
|
||||
(type
|
||||
((qualified_name dims_opt)
|
||||
(concat $1 $2))
|
||||
((primitive_type dims_opt)
|
||||
(concat $1 $2)))
|
||||
(qualified_name
|
||||
((qualified_name DOT IDENTIFIER)
|
||||
(concat $1 $2 $3))
|
||||
((IDENTIFIER)))
|
||||
(dims_opt
|
||||
(nil
|
||||
(identity ""))
|
||||
((dims)))
|
||||
(dims
|
||||
((dims BRACK_BLOCK)
|
||||
(concat $1 "[]"))
|
||||
((BRACK_BLOCK)
|
||||
(identity "[]"))))
|
||||
'(compilation_unit package_declaration import_declaration class_declaration field_declaration method_declaration formal_parameter constructor_declaration interface_declaration class_member_declaration interface_member_declaration formal_parameters)))
|
||||
"Parser table.")
|
||||
|
||||
(defun wisent-java-tags-wy--install-parser ()
|
||||
"Setup the Semantic Parser."
|
||||
(semantic-install-function-overrides
|
||||
'((parse-stream . wisent-parse-stream)))
|
||||
(setq semantic-parser-name "LALR"
|
||||
semantic--parse-table wisent-java-tags-wy--parse-table
|
||||
semantic-debug-parser-source "java-tags.wy"
|
||||
semantic-flex-keywords-obarray wisent-java-tags-wy--keyword-table
|
||||
semantic-lex-types-obarray wisent-java-tags-wy--token-table)
|
||||
;; Collect unmatched syntax lexical tokens
|
||||
(semantic-make-local-hook 'wisent-discarding-token-functions)
|
||||
(add-hook 'wisent-discarding-token-functions
|
||||
'wisent-collect-unmatched-syntax nil t))
|
||||
|
||||
|
||||
;;; Analyzers
|
||||
;;
|
||||
(define-lex-block-type-analyzer wisent-java-tags-wy--<block>-block-analyzer
|
||||
"block analyzer for <block> tokens."
|
||||
"\\s(\\|\\s)"
|
||||
'((("(" LPAREN PAREN_BLOCK)
|
||||
("{" LBRACE BRACE_BLOCK)
|
||||
("[" LBRACK BRACK_BLOCK))
|
||||
(")" RPAREN)
|
||||
("}" RBRACE)
|
||||
("]" RBRACK))
|
||||
)
|
||||
|
||||
(define-lex-string-type-analyzer wisent-java-tags-wy--<punctuation>-string-analyzer
|
||||
"string analyzer for <punctuation> tokens."
|
||||
"\\(\\s.\\|\\s$\\|\\s'\\)+"
|
||||
'((COMP . "~")
|
||||
(OROR . "||")
|
||||
(OREQ . "|=")
|
||||
(OR . "|")
|
||||
(XOREQ . "^=")
|
||||
(XOR . "^")
|
||||
(QUESTION . "?")
|
||||
(URSHIFTEQ . ">>>=")
|
||||
(URSHIFT . ">>>")
|
||||
(RSHIFTEQ . ">>=")
|
||||
(RSHIFT . ">>")
|
||||
(GTEQ . ">=")
|
||||
(GT . ">")
|
||||
(EQEQ . "==")
|
||||
(EQ . "=")
|
||||
(LTEQ . "<=")
|
||||
(LSHIFTEQ . "<<=")
|
||||
(LSHIFT . "<<")
|
||||
(LT . "<")
|
||||
(SEMICOLON . ";")
|
||||
(COLON . ":")
|
||||
(DIVEQ . "/=")
|
||||
(DIV . "/")
|
||||
(DOT . ".")
|
||||
(MINUSEQ . "-=")
|
||||
(MINUSMINUS . "--")
|
||||
(MINUS . "-")
|
||||
(COMMA . ",")
|
||||
(PLUSEQ . "+=")
|
||||
(PLUSPLUS . "++")
|
||||
(PLUS . "+")
|
||||
(MULTEQ . "*=")
|
||||
(MULT . "*")
|
||||
(ANDEQ . "&=")
|
||||
(ANDAND . "&&")
|
||||
(AND . "&")
|
||||
(MODEQ . "%=")
|
||||
(MOD . "%")
|
||||
(NOTEQ . "!=")
|
||||
(NOT . "!"))
|
||||
'punctuation)
|
||||
|
||||
(define-lex-regex-type-analyzer wisent-java-tags-wy--<symbol>-regexp-analyzer
|
||||
"regexp analyzer for <symbol> tokens."
|
||||
"\\(\\sw\\|\\s_\\)+"
|
||||
nil
|
||||
'IDENTIFIER)
|
||||
|
||||
(define-lex-regex-type-analyzer wisent-java-tags-wy--<unicode>-regexp-analyzer
|
||||
"regexp analyzer for <unicode> tokens."
|
||||
"\\\\u[0-9a-f][0-9a-f][0-9a-f][0-9a-f]"
|
||||
nil
|
||||
'unicodecharacter)
|
||||
|
||||
(define-lex-regex-type-analyzer wisent-java-tags-wy--<number>-regexp-analyzer
|
||||
"regexp analyzer for <number> tokens."
|
||||
semantic-lex-number-expression
|
||||
nil
|
||||
'NUMBER_LITERAL)
|
||||
|
||||
(define-lex-sexp-type-analyzer wisent-java-tags-wy--<string>-sexp-analyzer
|
||||
"sexp analyzer for <string> tokens."
|
||||
"\\s\""
|
||||
'STRING_LITERAL)
|
||||
|
||||
(define-lex-keyword-type-analyzer wisent-java-tags-wy--<keyword>-keyword-analyzer
|
||||
"keyword analyzer for <keyword> tokens."
|
||||
"\\(\\sw\\|\\s_\\)+")
|
||||
|
||||
|
||||
;;; Epilogue
|
||||
;;
|
||||
;; Define the lexer for this grammar
|
||||
(define-lex wisent-java-tags-lexer
|
||||
"Lexical analyzer that handles Java buffers.
|
||||
It ignores whitespaces, newlines and comments."
|
||||
semantic-lex-ignore-whitespace
|
||||
semantic-lex-ignore-newline
|
||||
semantic-lex-ignore-comments
|
||||
;;;; Auto-generated analyzers.
|
||||
wisent-java-tags-wy--<number>-regexp-analyzer
|
||||
wisent-java-tags-wy--<string>-sexp-analyzer
|
||||
;; Must detect keywords before other symbols
|
||||
wisent-java-tags-wy--<keyword>-keyword-analyzer
|
||||
wisent-java-tags-wy--<symbol>-regexp-analyzer
|
||||
wisent-java-tags-wy--<punctuation>-string-analyzer
|
||||
wisent-java-tags-wy--<block>-block-analyzer
|
||||
;; In theory, Unicode chars should be turned into normal chars
|
||||
;; and then combined into regular ascii keywords and text. This
|
||||
;; analyzer just keeps these things from making the lexer go boom.
|
||||
wisent-java-tags-wy--<unicode>-regexp-analyzer
|
||||
;;;;
|
||||
semantic-lex-default-action)
|
||||
|
||||
(provide 'semantic/wisent/javat-wy)
|
||||
|
||||
;;; semantic/wisent/javat-wy.el ends here
|
|
@ -1,530 +0,0 @@
|
|||
;;; semantic/wisent/js-wy.el --- Generated parser support file
|
||||
|
||||
;; Copyright (C) 2005, 2009-2013 Free Software Foundation, Inc.
|
||||
;; Copyright (C) 1998-2011 Ecma International.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
;; GNU Emacs is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
;; the Free Software Foundation, either version 3 of the License, or
|
||||
;; (at your option) any later version.
|
||||
|
||||
;; GNU Emacs is distributed in the hope that it will be useful,
|
||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;; GNU General Public License for more details.
|
||||
|
||||
;; You should have received a copy of the GNU General Public License
|
||||
;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/js.wy.
|
||||
|
||||
;; It is derived from the grammar in the ECMAScript Language
|
||||
;; Specification published at
|
||||
;;
|
||||
;; http://www.ecma-international.org/publications/standards/Ecma-262.htm
|
||||
;;
|
||||
;; and redistributed under the following license:
|
||||
;;
|
||||
;; Redistribution and use in source and binary forms, with or without
|
||||
;; modification, are permitted provided that the following conditions
|
||||
;; are met:
|
||||
;;
|
||||
;; 1. Redistributions of source code must retain the above copyright
|
||||
;; notice, this list of conditions and the following disclaimer.
|
||||
;;
|
||||
;; 2. Redistributions in binary form must reproduce the above
|
||||
;; copyright notice, this list of conditions and the following
|
||||
;; disclaimer in the documentation and/or other materials provided
|
||||
;; with the distribution.
|
||||
;;
|
||||
;; 3. Neither the name of the authors nor Ecma International may be
|
||||
;; used to endorse or promote products derived from this software
|
||||
;; without specific prior written permission. THIS SOFTWARE IS
|
||||
;; PROVIDED BY THE ECMA INTERNATIONAL "AS IS" AND ANY EXPRESS OR
|
||||
;; IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
||||
;; WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
;; ARE DISCLAIMED. IN NO EVENT SHALL ECMA INTERNATIONAL BE LIABLE FOR
|
||||
;; ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
;; CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT
|
||||
;; OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
|
||||
;; BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
;; LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
;; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
|
||||
;; USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
|
||||
;; DAMAGE.
|
||||
|
||||
;;; Code:
|
||||
|
||||
(require 'semantic/lex)
|
||||
(eval-when-compile (require 'semantic/bovine))
|
||||
|
||||
;;; Prologue
|
||||
;;
|
||||
(declare-function semantic-parse-region "semantic"
|
||||
(start end &optional nonterminal depth returnonerror))
|
||||
|
||||
;;; Declarations
|
||||
;;
|
||||
(defconst wisent-javascript-jv-wy--keyword-table
|
||||
(semantic-lex-make-keyword-table
|
||||
'(("if" . IF)
|
||||
("break" . BREAK)
|
||||
("continue" . CONTINUE)
|
||||
("else" . ELSE)
|
||||
("for" . FOR)
|
||||
("function" . FUNCTION)
|
||||
("this" . THIS)
|
||||
("return" . RETURN)
|
||||
("while" . WHILE)
|
||||
("void" . VOID_SYMBOL)
|
||||
("new" . NEW)
|
||||
("delete" . DELETE)
|
||||
("var" . VAR)
|
||||
("with" . WITH)
|
||||
("typeof" . TYPEOF)
|
||||
("in" . IN))
|
||||
'(("in" summary "in something")
|
||||
("typeof" summary "typeof ")
|
||||
("with" summary "with ")
|
||||
("var" summary "var <variablename> [= value];")
|
||||
("delete" summary "delete(<objectreference>) - Deletes the object.")
|
||||
("new" summary "new <objecttype> - Creates a new object.")
|
||||
("void" summary "Method return type: void <name> ...")
|
||||
("while" summary "while (<expr>) <stmt> | do <stmt> while (<expr>);")
|
||||
("return" summary "return [<expr>] ;")
|
||||
("this" summary "this")
|
||||
("function" summary "function declaration blah blah")
|
||||
("for" summary "for ([<init-expr>]; [<expr>]; [<update-expr>]) <stmt>")
|
||||
("else" summary "if (<expr>) <stmt> else <stmt>")
|
||||
("continue" summary "continue [<label>] ;")
|
||||
("break" summary "break [<label>] ;")
|
||||
("if" summary "if (<expr>) <stmt> [else <stmt>] (jv)")))
|
||||
"Table of language keywords.")
|
||||
|
||||
(defconst wisent-javascript-jv-wy--token-table
|
||||
(semantic-lex-make-type-table
|
||||
'(("<no-type>"
|
||||
(NULL_TOKEN)
|
||||
(QUERY)
|
||||
(TRUE)
|
||||
(FALSE))
|
||||
("number"
|
||||
(NUMBER))
|
||||
("string"
|
||||
(STRING))
|
||||
("symbol"
|
||||
(VARIABLE))
|
||||
("close-paren"
|
||||
(CLOSE_SQ_BRACKETS . "]")
|
||||
(END_BLOCK . "}")
|
||||
(CLOSE_PARENTHESIS . ")"))
|
||||
("open-paren"
|
||||
(OPEN_SQ_BRACKETS . "[")
|
||||
(START_BLOCK . "{")
|
||||
(OPEN_PARENTHESIS . "("))
|
||||
("block"
|
||||
(BRACK_BLOCK . "(OPEN_SQ_BRACKETS CLOSE_SQ_BRACKETS)")
|
||||
(BRACE_BLOCK . "(START_BLOCK END_BLOCK)")
|
||||
(PAREN_BLOCK . "(OPEN_PARENTHESIS CLOSE_PARENTHESIS)"))
|
||||
("punctuation"
|
||||
(ONES_COMPLIMENT . "~")
|
||||
(SEMICOLON . ";")
|
||||
(LINE_TERMINATOR . "\n")
|
||||
(LESS_THAN . "<")
|
||||
(DOT . ".")
|
||||
(COMMA . ",")
|
||||
(COLON . ":")
|
||||
(DIV . "/")
|
||||
(DECREMENT . "--")
|
||||
(INCREMENT . "++")
|
||||
(PLUS_EQUALS . "+=")
|
||||
(PLUS . "+")
|
||||
(MULTIPLY_EQUALS . "*=")
|
||||
(MULTIPLY . "*")
|
||||
(MOD_EQUALS . "%=")
|
||||
(MOD . "%")
|
||||
(MINUS_EQUALS . "-=")
|
||||
(MINUS . "-")
|
||||
(LS_EQUAL . "<=")
|
||||
(LOGICAL_NOT . "!!")
|
||||
(LOGICAL_OR . "||")
|
||||
(LOGICAL_AND . "&&")
|
||||
(GT_EQUAL . ">=")
|
||||
(GREATER_THAN . ">")
|
||||
(EQUALS . "==")
|
||||
(DIV_EQUALS . "/=")
|
||||
(NOT_EQUAL . "!=")
|
||||
(BITWISE_SHIFT_RIGHT_ZERO_FILL_EQUALS . ">>>=")
|
||||
(BITWISE_SHIFT_RIGHT_ZERO_FILL . ">>>")
|
||||
(BITWISE_SHIFT_RIGHT_EQUALS . ">>=")
|
||||
(BITWISE_SHIFT_RIGHT . ">>")
|
||||
(BITWISE_SHIFT_LEFT_EQUALS . "<<=")
|
||||
(BITWISE_SHIFT_LEFT . "<<")
|
||||
(BITWISE_OR_EQUALS . "|=")
|
||||
(BITWISE_OR . "|")
|
||||
(BITWISE_EXCLUSIVE_OR_EQUALS . "^=")
|
||||
(BITWISE_EXCLUSIVE_OR . "^")
|
||||
(BITWISE_AND_EQUALS . "&=")
|
||||
(BITWISE_AND . "&")
|
||||
(ASSIGN_SYMBOL . "=")))
|
||||
'(("number" :declared t)
|
||||
("string" :declared t)
|
||||
("symbol" :declared t)
|
||||
("keyword" :declared t)
|
||||
("block" :declared t)
|
||||
("punctuation" :declared t)))
|
||||
"Table of lexical tokens.")
|
||||
|
||||
(defconst wisent-javascript-jv-wy--parse-table
|
||||
(progn
|
||||
(eval-when-compile
|
||||
(require 'semantic/wisent/comp))
|
||||
(wisent-compile-grammar
|
||||
'((ASSIGN_SYMBOL BITWISE_AND BITWISE_AND_EQUALS BITWISE_EXCLUSIVE_OR BITWISE_EXCLUSIVE_OR_EQUALS BITWISE_OR BITWISE_OR_EQUALS BITWISE_SHIFT_LEFT BITWISE_SHIFT_LEFT_EQUALS BITWISE_SHIFT_RIGHT BITWISE_SHIFT_RIGHT_EQUALS BITWISE_SHIFT_RIGHT_ZERO_FILL BITWISE_SHIFT_RIGHT_ZERO_FILL_EQUALS NOT_EQUAL DIV_EQUALS EQUALS GREATER_THAN GT_EQUAL LOGICAL_AND LOGICAL_OR LOGICAL_NOT LS_EQUAL MINUS MINUS_EQUALS MOD MOD_EQUALS MULTIPLY MULTIPLY_EQUALS PLUS PLUS_EQUALS INCREMENT DECREMENT DIV COLON COMMA DOT LESS_THAN LINE_TERMINATOR SEMICOLON ONES_COMPLIMENT PAREN_BLOCK BRACE_BLOCK BRACK_BLOCK OPEN_PARENTHESIS CLOSE_PARENTHESIS START_BLOCK END_BLOCK OPEN_SQ_BRACKETS CLOSE_SQ_BRACKETS IF BREAK CONTINUE ELSE FOR FUNCTION THIS RETURN WHILE VOID_SYMBOL NEW DELETE VAR WITH TYPEOF IN VARIABLE STRING NUMBER FALSE TRUE QUERY NULL_TOKEN)
|
||||
((left PLUS MINUS)
|
||||
(left MULTIPLY DIV MOD)
|
||||
(nonassoc FALSE)
|
||||
(nonassoc HIGHER_THAN_FALSE)
|
||||
(nonassoc ELSE)
|
||||
(nonassoc LOWER_THAN_CLOSE_PARENTHESIS)
|
||||
(nonassoc CLOSE_PARENTHESIS))
|
||||
(Program
|
||||
((SourceElement)))
|
||||
(SourceElement
|
||||
((Statement))
|
||||
((FunctionDeclaration)))
|
||||
(Statement
|
||||
((Block))
|
||||
((VariableStatement))
|
||||
((EmptyStatement))
|
||||
((ExpressionStatement))
|
||||
((IfStatement))
|
||||
((IterationExpression))
|
||||
((ContinueStatement))
|
||||
((BreakStatement))
|
||||
((ReturnStatement))
|
||||
((WithStatement)))
|
||||
(FunctionDeclaration
|
||||
((FUNCTION VARIABLE FormalParameterListBlock Block)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-function $2 nil $3))))
|
||||
(FormalParameterListBlock
|
||||
((PAREN_BLOCK)
|
||||
(semantic-parse-region
|
||||
(car $region1)
|
||||
(cdr $region1)
|
||||
'FormalParameterList 1)))
|
||||
(FormalParameterList
|
||||
((OPEN_PARENTHESIS)
|
||||
nil)
|
||||
((VARIABLE)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $1 nil nil)))
|
||||
((CLOSE_PARENTHESIS)
|
||||
nil)
|
||||
((COMMA)
|
||||
nil))
|
||||
(StatementList
|
||||
((Statement))
|
||||
((StatementList Statement)))
|
||||
(Block
|
||||
((BRACE_BLOCK)))
|
||||
(BlockExpand
|
||||
((START_BLOCK StatementList END_BLOCK))
|
||||
((START_BLOCK END_BLOCK)))
|
||||
(VariableStatement
|
||||
((VAR VariableDeclarationList SEMICOLON)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $2 nil nil))))
|
||||
(VariableDeclarationList
|
||||
((VariableDeclaration)
|
||||
(list $1))
|
||||
((VariableDeclarationList COMMA VariableDeclaration)
|
||||
(append $1
|
||||
(list $3))))
|
||||
(VariableDeclaration
|
||||
((VARIABLE)
|
||||
(append
|
||||
(list $1 nil)
|
||||
$region))
|
||||
((VARIABLE Initializer)
|
||||
(append
|
||||
(cons $1 $2)
|
||||
$region)))
|
||||
(Initializer
|
||||
((ASSIGN_SYMBOL AssignmentExpression)
|
||||
(list $2)))
|
||||
(EmptyStatement
|
||||
((SEMICOLON)))
|
||||
(ExpressionStatement
|
||||
((Expression SEMICOLON)))
|
||||
(IfStatement
|
||||
((IF OPEN_PARENTHESIS Expression CLOSE_PARENTHESIS Statement)
|
||||
[HIGHER_THAN_FALSE])
|
||||
((IF OPEN_PARENTHESIS Expression CLOSE_PARENTHESIS Statement ELSE Statement))
|
||||
((IF OPEN_PARENTHESIS FALSE CLOSE_PARENTHESIS Statement))
|
||||
((IF OPEN_PARENTHESIS LeftHandSideExpression AssignmentOperator AssignmentExpression CLOSE_PARENTHESIS Statement)))
|
||||
(IterationExpression
|
||||
((WHILE OPEN_PARENTHESIS Expression CLOSE_PARENTHESIS Statement)
|
||||
[HIGHER_THAN_FALSE])
|
||||
((WHILE OPEN_PARENTHESIS FALSE CLOSE_PARENTHESIS Statement))
|
||||
((WHILE OPEN_PARENTHESIS LeftHandSideExpression AssignmentOperator AssignmentExpression CLOSE_PARENTHESIS Statement))
|
||||
((FOR OPEN_PARENTHESIS OptionalExpression SEMICOLON OptionalExpression SEMICOLON OptionalExpression CLOSE_PARENTHESIS Statement))
|
||||
((FOR OPEN_PARENTHESIS VAR VariableDeclarationList SEMICOLON OptionalExpression SEMICOLON OptionalExpression CLOSE_PARENTHESIS Statement))
|
||||
((FOR OPEN_PARENTHESIS LeftHandSideExpression IN Expression CLOSE_PARENTHESIS Statement))
|
||||
((FOR OPEN_PARENTHESIS VAR VARIABLE OptionalInitializer IN Expression CLOSE_PARENTHESIS Statement)))
|
||||
(ContinueStatement
|
||||
((CONTINUE SEMICOLON)))
|
||||
(BreakStatement
|
||||
((BREAK SEMICOLON)))
|
||||
(ReturnStatement
|
||||
((RETURN Expression SEMICOLON))
|
||||
((RETURN SEMICOLON)))
|
||||
(WithStatement
|
||||
((WITH OPEN_PARENTHESIS Expression CLOSE_PARENTHESIS Statement)))
|
||||
(OptionalInitializer
|
||||
((Initializer))
|
||||
(nil))
|
||||
(PrimaryExpression
|
||||
((THIS))
|
||||
((VARIABLE))
|
||||
((NUMBER))
|
||||
((STRING))
|
||||
((NULL_TOKEN))
|
||||
((TRUE))
|
||||
((FALSE))
|
||||
((OPEN_PARENTHESIS Expression CLOSE_PARENTHESIS)))
|
||||
(MemberExpression
|
||||
((PrimaryExpression))
|
||||
((MemberExpression OPEN_SQ_BRACKETS Expression CLOSE_SQ_BRACKETS))
|
||||
((MemberExpression DOT VARIABLE))
|
||||
((NEW MemberExpression Arguments)))
|
||||
(NewExpression
|
||||
((MemberExpression))
|
||||
((NEW NewExpression)))
|
||||
(CallExpression
|
||||
((MemberExpression Arguments))
|
||||
((CallExpression Arguments))
|
||||
((CallExpression OPEN_SQ_BRACKETS Expression CLOSE_SQ_BRACKETS))
|
||||
((CallExpression DOT VARIABLE)))
|
||||
(Arguments
|
||||
((OPEN_PARENTHESIS CLOSE_PARENTHESIS))
|
||||
((OPEN_PARENTHESIS ArgumentList CLOSE_PARENTHESIS)))
|
||||
(ArgumentList
|
||||
((AssignmentExpression))
|
||||
((ArgumentList COMMA AssignmentExpression)))
|
||||
(LeftHandSideExpression
|
||||
((NewExpression))
|
||||
((CallExpression)))
|
||||
(PostfixExpression
|
||||
((LeftHandSideExpression))
|
||||
((LeftHandSideExpression INCREMENT))
|
||||
((LeftHandSideExpression DECREMENT)))
|
||||
(UnaryExpression
|
||||
((PostfixExpression))
|
||||
((DELETE UnaryExpression))
|
||||
((VOID_SYMBOL UnaryExpression))
|
||||
((TYPEOF UnaryExpression))
|
||||
((INCREMENT UnaryExpression))
|
||||
((DECREMENT UnaryExpression))
|
||||
((PLUS UnaryExpression))
|
||||
((MINUS UnaryExpression))
|
||||
((ONES_COMPLIMENT UnaryExpression))
|
||||
((LOGICAL_NOT UnaryExpression)))
|
||||
(MultiplicativeExpression
|
||||
((UnaryExpression))
|
||||
((MultiplicativeExpression MULTIPLY UnaryExpression))
|
||||
((MultiplicativeExpression DIV UnaryExpression))
|
||||
((MultiplicativeExpression MOD UnaryExpression)))
|
||||
(AdditiveExpression
|
||||
((MultiplicativeExpression))
|
||||
((AdditiveExpression PLUS MultiplicativeExpression))
|
||||
((AdditiveExpression MINUS MultiplicativeExpression)))
|
||||
(ShiftExpression
|
||||
((AdditiveExpression))
|
||||
((ShiftExpression BITWISE_SHIFT_LEFT AdditiveExpression))
|
||||
((ShiftExpression BITWISE_SHIFT_RIGHT AdditiveExpression))
|
||||
((ShiftExpression BITWISE_SHIFT_RIGHT_ZERO_FILL AdditiveExpression)))
|
||||
(RelationalExpression
|
||||
((ShiftExpression))
|
||||
((RelationalExpression LESS_THAN ShiftExpression))
|
||||
((RelationalExpression GREATER_THAN ShiftExpression))
|
||||
((RelationalExpression LS_EQUAL ShiftExpression))
|
||||
((RelationalExpression GT_EQUAL ShiftExpression)))
|
||||
(EqualityExpression
|
||||
((RelationalExpression))
|
||||
((EqualityExpression EQUALS RelationalExpression))
|
||||
((EqualityExpression NOT_EQUAL RelationalExpression)))
|
||||
(BitwiseANDExpression
|
||||
((EqualityExpression))
|
||||
((BitwiseANDExpression BITWISE_AND EqualityExpression)))
|
||||
(BitwiseXORExpression
|
||||
((BitwiseANDExpression))
|
||||
((BitwiseXORExpression BITWISE_EXCLUSIVE_OR BitwiseANDExpression)))
|
||||
(BitwiseORExpression
|
||||
((BitwiseXORExpression))
|
||||
((BitwiseORExpression BITWISE_OR BitwiseXORExpression)))
|
||||
(LogicalANDExpression
|
||||
((BitwiseORExpression))
|
||||
((LogicalANDExpression LOGICAL_AND BitwiseORExpression)))
|
||||
(LogicalORExpression
|
||||
((LogicalANDExpression))
|
||||
((LogicalORExpression LOGICAL_OR LogicalANDExpression)))
|
||||
(ConditionalExpression
|
||||
((LogicalORExpression))
|
||||
((LogicalORExpression QUERY AssignmentExpression COLON AssignmentExpression)))
|
||||
(AssignmentExpression
|
||||
((ConditionalExpression))
|
||||
((LeftHandSideExpression AssignmentOperator AssignmentExpression)
|
||||
[LOWER_THAN_CLOSE_PARENTHESIS]))
|
||||
(AssignmentOperator
|
||||
((ASSIGN_SYMBOL))
|
||||
((MULTIPLY_EQUALS))
|
||||
((DIV_EQUALS))
|
||||
((MOD_EQUALS))
|
||||
((PLUS_EQUALS))
|
||||
((MINUS_EQUALS))
|
||||
((BITWISE_SHIFT_LEFT_EQUALS))
|
||||
((BITWISE_SHIFT_RIGHT_EQUALS))
|
||||
((BITWISE_SHIFT_RIGHT_ZERO_FILL_EQUALS))
|
||||
((BITWISE_AND_EQUALS))
|
||||
((BITWISE_EXCLUSIVE_OR_EQUALS))
|
||||
((BITWISE_OR_EQUALS)))
|
||||
(Expression
|
||||
((AssignmentExpression))
|
||||
((Expression COMMA AssignmentExpression)))
|
||||
(OptionalExpression
|
||||
((Expression))
|
||||
(nil)))
|
||||
'(Program FormalParameterList)))
|
||||
"Parser table.")
|
||||
|
||||
(defun wisent-javascript-jv-wy--install-parser ()
|
||||
"Setup the Semantic Parser."
|
||||
(semantic-install-function-overrides
|
||||
'((parse-stream . wisent-parse-stream)))
|
||||
(setq semantic-parser-name "LALR"
|
||||
semantic--parse-table wisent-javascript-jv-wy--parse-table
|
||||
semantic-debug-parser-source "js.wy"
|
||||
semantic-flex-keywords-obarray wisent-javascript-jv-wy--keyword-table
|
||||
semantic-lex-types-obarray wisent-javascript-jv-wy--token-table)
|
||||
;; Collect unmatched syntax lexical tokens
|
||||
(semantic-make-local-hook 'wisent-discarding-token-functions)
|
||||
(add-hook 'wisent-discarding-token-functions
|
||||
'wisent-collect-unmatched-syntax nil t))
|
||||
|
||||
|
||||
;;; Analyzers
|
||||
;;
|
||||
(define-lex-block-type-analyzer wisent-javascript-jv-wy--<block>-block-analyzer
|
||||
"block analyzer for <block> tokens."
|
||||
"\\s(\\|\\s)"
|
||||
'((("(" OPEN_PARENTHESIS PAREN_BLOCK)
|
||||
("{" START_BLOCK BRACE_BLOCK)
|
||||
("[" OPEN_SQ_BRACKETS BRACK_BLOCK))
|
||||
(")" CLOSE_PARENTHESIS)
|
||||
("}" END_BLOCK)
|
||||
("]" CLOSE_SQ_BRACKETS))
|
||||
)
|
||||
|
||||
(define-lex-regex-type-analyzer wisent-javascript-jv-wy--<symbol>-regexp-analyzer
|
||||
"regexp analyzer for <symbol> tokens."
|
||||
"\\(\\sw\\|\\s_\\)+"
|
||||
nil
|
||||
'VARIABLE)
|
||||
|
||||
(define-lex-regex-type-analyzer wisent-javascript-jv-wy--<number>-regexp-analyzer
|
||||
"regexp analyzer for <number> tokens."
|
||||
semantic-lex-number-expression
|
||||
nil
|
||||
'NUMBER)
|
||||
|
||||
(define-lex-string-type-analyzer wisent-javascript-jv-wy--<punctuation>-string-analyzer
|
||||
"string analyzer for <punctuation> tokens."
|
||||
"\\(\\s.\\|\\s$\\|\\s'\\)+"
|
||||
'((ONES_COMPLIMENT . "~")
|
||||
(SEMICOLON . ";")
|
||||
(LINE_TERMINATOR . "\n")
|
||||
(LESS_THAN . "<")
|
||||
(DOT . ".")
|
||||
(COMMA . ",")
|
||||
(COLON . ":")
|
||||
(DIV . "/")
|
||||
(DECREMENT . "--")
|
||||
(INCREMENT . "++")
|
||||
(PLUS_EQUALS . "+=")
|
||||
(PLUS . "+")
|
||||
(MULTIPLY_EQUALS . "*=")
|
||||
(MULTIPLY . "*")
|
||||
(MOD_EQUALS . "%=")
|
||||
(MOD . "%")
|
||||
(MINUS_EQUALS . "-=")
|
||||
(MINUS . "-")
|
||||
(LS_EQUAL . "<=")
|
||||
(LOGICAL_NOT . "!!")
|
||||
(LOGICAL_OR . "||")
|
||||
(LOGICAL_AND . "&&")
|
||||
(GT_EQUAL . ">=")
|
||||
(GREATER_THAN . ">")
|
||||
(EQUALS . "==")
|
||||
(DIV_EQUALS . "/=")
|
||||
(NOT_EQUAL . "!=")
|
||||
(BITWISE_SHIFT_RIGHT_ZERO_FILL_EQUALS . ">>>=")
|
||||
(BITWISE_SHIFT_RIGHT_ZERO_FILL . ">>>")
|
||||
(BITWISE_SHIFT_RIGHT_EQUALS . ">>=")
|
||||
(BITWISE_SHIFT_RIGHT . ">>")
|
||||
(BITWISE_SHIFT_LEFT_EQUALS . "<<=")
|
||||
(BITWISE_SHIFT_LEFT . "<<")
|
||||
(BITWISE_OR_EQUALS . "|=")
|
||||
(BITWISE_OR . "|")
|
||||
(BITWISE_EXCLUSIVE_OR_EQUALS . "^=")
|
||||
(BITWISE_EXCLUSIVE_OR . "^")
|
||||
(BITWISE_AND_EQUALS . "&=")
|
||||
(BITWISE_AND . "&")
|
||||
(ASSIGN_SYMBOL . "="))
|
||||
'punctuation)
|
||||
|
||||
(define-lex-sexp-type-analyzer wisent-javascript-jv-wy--<string>-sexp-analyzer
|
||||
"sexp analyzer for <string> tokens."
|
||||
"\\s\""
|
||||
'STRING)
|
||||
|
||||
(define-lex-keyword-type-analyzer wisent-javascript-jv-wy--<keyword>-keyword-analyzer
|
||||
"keyword analyzer for <keyword> tokens."
|
||||
"\\(\\sw\\|\\s_\\)+")
|
||||
|
||||
|
||||
;;; Epilogue
|
||||
;;
|
||||
;;here something like:
|
||||
;;(define-lex wisent-java-tags-lexer
|
||||
;; should go
|
||||
(define-lex javascript-lexer-jv
|
||||
"javascript thingy"
|
||||
;;std stuff
|
||||
semantic-lex-ignore-whitespace
|
||||
semantic-lex-ignore-newline
|
||||
semantic-lex-ignore-comments
|
||||
|
||||
;;stuff generated from the wy file(one for each "type" declaration)
|
||||
wisent-javascript-jv-wy--<number>-regexp-analyzer
|
||||
wisent-javascript-jv-wy--<string>-sexp-analyzer
|
||||
|
||||
wisent-javascript-jv-wy--<keyword>-keyword-analyzer
|
||||
|
||||
wisent-javascript-jv-wy--<symbol>-regexp-analyzer
|
||||
wisent-javascript-jv-wy--<punctuation>-string-analyzer
|
||||
wisent-javascript-jv-wy--<block>-block-analyzer
|
||||
|
||||
|
||||
;;;;more std stuff
|
||||
semantic-lex-default-action
|
||||
)
|
||||
|
||||
(provide 'semantic/wisent/js-wy)
|
||||
|
||||
;;; semantic/wisent/js-wy.el ends here
|
|
@ -1,847 +0,0 @@
|
|||
;;; semantic/wisent/python-wy.el --- Generated parser support file
|
||||
|
||||
;; Copyright (C) 2002-2013 Free Software Foundation, Inc.
|
||||
;; Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
|
||||
;; 2009, 2010 Python Software Foundation; All Rights Reserved
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
;; GNU Emacs is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
;; the Free Software Foundation, either version 3 of the License, or
|
||||
;; (at your option) any later version.
|
||||
|
||||
;; GNU Emacs is distributed in the hope that it will be useful,
|
||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;; GNU General Public License for more details.
|
||||
|
||||
;; You should have received a copy of the GNU General Public License
|
||||
;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/python.wy.
|
||||
;; It is derived in part from the Python grammar, used under the
|
||||
;; following license:
|
||||
;;
|
||||
;; PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2
|
||||
;; --------------------------------------------
|
||||
;; 1. This LICENSE AGREEMENT is between the Python Software Foundation
|
||||
;; ("PSF"), and the Individual or Organization ("Licensee") accessing
|
||||
;; and otherwise using this software ("Python") in source or binary
|
||||
;; form and its associated documentation.
|
||||
;;
|
||||
;; 2. Subject to the terms and conditions of this License Agreement,
|
||||
;; PSF hereby grants Licensee a nonexclusive, royalty-free, world-wide
|
||||
;; license to reproduce, analyze, test, perform and/or display
|
||||
;; publicly, prepare derivative works, distribute, and otherwise use
|
||||
;; Python alone or in any derivative version, provided, however, that
|
||||
;; PSF's License Agreement and PSF's notice of copyright, i.e.,
|
||||
;; "Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
|
||||
;; 2009, 2010 Python Software Foundation; All Rights Reserved" are
|
||||
;; retained in Python alone or in any derivative version prepared by
|
||||
;; Licensee.
|
||||
;;
|
||||
;; 3. In the event Licensee prepares a derivative work that is based
|
||||
;; on or incorporates Python or any part thereof, and wants to make
|
||||
;; the derivative work available to others as provided herein, then
|
||||
;; Licensee hereby agrees to include in any such work a brief summary
|
||||
;; of the changes made to Python.
|
||||
;;
|
||||
;; 4. PSF is making Python available to Licensee on an "AS IS"
|
||||
;; basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR
|
||||
;; IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND
|
||||
;; DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS
|
||||
;; FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON WILL NOT
|
||||
;; INFRINGE ANY THIRD PARTY RIGHTS.
|
||||
;;
|
||||
;; 5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON
|
||||
;; FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS A
|
||||
;; RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON, OR
|
||||
;; ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF.
|
||||
;;
|
||||
;; 6. This License Agreement will automatically terminate upon a
|
||||
;; material breach of its terms and conditions.
|
||||
;;
|
||||
;; 7. Nothing in this License Agreement shall be deemed to create any
|
||||
;; relationship of agency, partnership, or joint venture between PSF
|
||||
;; and Licensee. This License Agreement does not grant permission to
|
||||
;; use PSF trademarks or trade name in a trademark sense to endorse or
|
||||
;; promote products or services of Licensee, or any third party.
|
||||
;;
|
||||
;; 8. By copying, installing or otherwise using Python, Licensee
|
||||
;; agrees to be bound by the terms and conditions of this License
|
||||
;; Agreement.
|
||||
|
||||
;;; Code:
|
||||
|
||||
(require 'semantic/lex)
|
||||
(eval-when-compile (require 'semantic/bovine))
|
||||
|
||||
;;; Prologue
|
||||
;;
|
||||
(declare-function wisent-python-reconstitute-function-tag
|
||||
"semantic/wisent/python" (tag suite))
|
||||
(declare-function wisent-python-reconstitute-class-tag "semantic/wisent/python"
|
||||
(tag))
|
||||
(declare-function semantic-parse-region "semantic"
|
||||
(start end &optional nonterminal depth returnonerror))
|
||||
|
||||
;;; Declarations
|
||||
;;
|
||||
(defconst wisent-python-wy--keyword-table
|
||||
(semantic-lex-make-keyword-table
|
||||
'(("and" . AND)
|
||||
("as" . AS)
|
||||
("assert" . ASSERT)
|
||||
("break" . BREAK)
|
||||
("class" . CLASS)
|
||||
("continue" . CONTINUE)
|
||||
("def" . DEF)
|
||||
("del" . DEL)
|
||||
("elif" . ELIF)
|
||||
("else" . ELSE)
|
||||
("except" . EXCEPT)
|
||||
("exec" . EXEC)
|
||||
("finally" . FINALLY)
|
||||
("for" . FOR)
|
||||
("from" . FROM)
|
||||
("global" . GLOBAL)
|
||||
("if" . IF)
|
||||
("import" . IMPORT)
|
||||
("in" . IN)
|
||||
("is" . IS)
|
||||
("lambda" . LAMBDA)
|
||||
("not" . NOT)
|
||||
("or" . OR)
|
||||
("pass" . PASS)
|
||||
("print" . PRINT)
|
||||
("raise" . RAISE)
|
||||
("return" . RETURN)
|
||||
("try" . TRY)
|
||||
("while" . WHILE)
|
||||
("with" . WITH)
|
||||
("yield" . YIELD))
|
||||
'(("yield" summary "Create a generator function")
|
||||
("with" summary "Start statement with an associated context object")
|
||||
("while" summary "Start a 'while' loop")
|
||||
("try" summary "Start of statements protected by exception handlers")
|
||||
("return" summary "Return from a function")
|
||||
("raise" summary "Raise an exception")
|
||||
("print" summary "Print each argument to standard output")
|
||||
("pass" summary "Statement that does nothing")
|
||||
("or" summary "Binary logical 'or' operator")
|
||||
("not" summary "Unary boolean negation operator")
|
||||
("lambda" summary "Create anonymous function")
|
||||
("is" summary "Binary operator that tests for object equality")
|
||||
("in" summary "Part of 'for' statement ")
|
||||
("import" summary "Load specified modules")
|
||||
("if" summary "Start 'if' conditional statement")
|
||||
("global" summary "Declare one or more symbols as global symbols")
|
||||
("from" summary "Modify behavior of 'import' statement")
|
||||
("for" summary "Start a 'for' loop")
|
||||
("finally" summary "Specify code to be executed after 'try' statements whether or not an exception occurred")
|
||||
("exec" summary "Dynamically execute Python code")
|
||||
("except" summary "Specify exception handlers along with 'try' keyword")
|
||||
("else" summary "Start the 'else' clause following an 'if' statement")
|
||||
("elif" summary "Shorthand for 'else if' following an 'if' statement")
|
||||
("del" summary "Delete specified objects, i.e., undo what assignment did")
|
||||
("def" summary "Define a new function")
|
||||
("continue" summary "Skip to the next iteration of enclosing 'for' or 'while' loop")
|
||||
("class" summary "Define a new class")
|
||||
("break" summary "Terminate 'for' or 'while' loop")
|
||||
("assert" summary "Raise AssertionError exception if <expr> is false")
|
||||
("as" summary "EXPR as NAME makes value of EXPR available as variable NAME")
|
||||
("and" summary "Logical AND binary operator ... ")))
|
||||
"Table of language keywords.")
|
||||
|
||||
(defconst wisent-python-wy--token-table
|
||||
(semantic-lex-make-type-table
|
||||
'(("symbol"
|
||||
(NAME))
|
||||
("number"
|
||||
(NUMBER_LITERAL))
|
||||
("string"
|
||||
(STRING_LITERAL))
|
||||
("punctuation"
|
||||
(AT . "@")
|
||||
(BACKQUOTE . "`")
|
||||
(ASSIGN . "=")
|
||||
(COMMA . ",")
|
||||
(SEMICOLON . ";")
|
||||
(COLON . ":")
|
||||
(BAR . "|")
|
||||
(TILDE . "~")
|
||||
(PERIOD . ".")
|
||||
(MINUS . "-")
|
||||
(PLUS . "+")
|
||||
(MOD . "%")
|
||||
(DIV . "/")
|
||||
(MULT . "*")
|
||||
(AMP . "&")
|
||||
(GT . ">")
|
||||
(LT . "<")
|
||||
(HAT . "^")
|
||||
(NE . "!=")
|
||||
(LTGT . "<>")
|
||||
(HATEQ . "^=")
|
||||
(OREQ . "|=")
|
||||
(AMPEQ . "&=")
|
||||
(MODEQ . "%=")
|
||||
(DIVEQ . "/=")
|
||||
(MULTEQ . "*=")
|
||||
(MINUSEQ . "-=")
|
||||
(PLUSEQ . "+=")
|
||||
(LE . "<=")
|
||||
(GE . ">=")
|
||||
(EQ . "==")
|
||||
(EXPONENT . "**")
|
||||
(GTGT . ">>")
|
||||
(LTLT . "<<")
|
||||
(DIVDIV . "//")
|
||||
(DIVDIVEQ . "//=")
|
||||
(EXPEQ . "**=")
|
||||
(GTGTEQ . ">>=")
|
||||
(LTLTEQ . "<<="))
|
||||
("close-paren"
|
||||
(RBRACK . "]")
|
||||
(RBRACE . "}")
|
||||
(RPAREN . ")"))
|
||||
("open-paren"
|
||||
(LBRACK . "[")
|
||||
(LBRACE . "{")
|
||||
(LPAREN . "("))
|
||||
("block"
|
||||
(BRACK_BLOCK . "(LBRACK RBRACK)")
|
||||
(BRACE_BLOCK . "(LBRACE RBRACE)")
|
||||
(PAREN_BLOCK . "(LPAREN RPAREN)"))
|
||||
("indentation"
|
||||
(INDENT_BLOCK . "(INDENT DEDENT)")
|
||||
(DEDENT . "[^:INDENT:]")
|
||||
(INDENT . "^\\s-+"))
|
||||
("newline"
|
||||
(NEWLINE . "\n"))
|
||||
("charquote"
|
||||
(BACKSLASH . "\\")))
|
||||
'(("keyword" :declared t)
|
||||
("symbol" :declared t)
|
||||
("number" :declared t)
|
||||
("punctuation" :declared t)
|
||||
("block" :declared t)))
|
||||
"Table of lexical tokens.")
|
||||
|
||||
(defconst wisent-python-wy--parse-table
|
||||
(progn
|
||||
(eval-when-compile
|
||||
(require 'semantic/wisent/comp))
|
||||
(wisent-compile-grammar
|
||||
'((BACKSLASH NEWLINE INDENT DEDENT INDENT_BLOCK PAREN_BLOCK BRACE_BLOCK BRACK_BLOCK LPAREN RPAREN LBRACE RBRACE LBRACK RBRACK LTLTEQ GTGTEQ EXPEQ DIVDIVEQ DIVDIV LTLT GTGT EXPONENT EQ GE LE PLUSEQ MINUSEQ MULTEQ DIVEQ MODEQ AMPEQ OREQ HATEQ LTGT NE HAT LT GT AMP MULT DIV MOD PLUS MINUS PERIOD TILDE BAR COLON SEMICOLON COMMA ASSIGN BACKQUOTE AT STRING_LITERAL NUMBER_LITERAL NAME AND AS ASSERT BREAK CLASS CONTINUE DEF DEL ELIF ELSE EXCEPT EXEC FINALLY FOR FROM GLOBAL IF IMPORT IN IS LAMBDA NOT OR PASS PRINT RAISE RETURN TRY WHILE WITH YIELD)
|
||||
nil
|
||||
(goal
|
||||
((NEWLINE))
|
||||
((simple_stmt))
|
||||
((compound_stmt)))
|
||||
(simple_stmt
|
||||
((small_stmt_list semicolon_opt NEWLINE)))
|
||||
(small_stmt_list
|
||||
((small_stmt))
|
||||
((small_stmt_list SEMICOLON small_stmt)))
|
||||
(small_stmt
|
||||
((expr_stmt))
|
||||
((print_stmt))
|
||||
((del_stmt))
|
||||
((pass_stmt))
|
||||
((flow_stmt))
|
||||
((import_stmt))
|
||||
((global_stmt))
|
||||
((exec_stmt))
|
||||
((assert_stmt)))
|
||||
(print_stmt
|
||||
((PRINT print_stmt_trailer)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(print_stmt_trailer
|
||||
((test_list_opt)
|
||||
nil)
|
||||
((GTGT test trailing_test_list_with_opt_comma_opt)
|
||||
nil))
|
||||
(trailing_test_list_with_opt_comma_opt
|
||||
(nil)
|
||||
((trailing_test_list comma_opt)
|
||||
nil))
|
||||
(trailing_test_list
|
||||
((COMMA test)
|
||||
nil)
|
||||
((trailing_test_list COMMA test)
|
||||
nil))
|
||||
(expr_stmt
|
||||
((testlist expr_stmt_trailer)
|
||||
(if
|
||||
(and $2
|
||||
(stringp $1)
|
||||
(string-match "^\\(\\sw\\|\\s_\\)+$" $1))
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $1 nil nil))
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil)))))
|
||||
(expr_stmt_trailer
|
||||
((augassign testlist))
|
||||
((eq_testlist_zom)))
|
||||
(eq_testlist_zom
|
||||
(nil)
|
||||
((eq_testlist_zom ASSIGN testlist)
|
||||
(identity $3)))
|
||||
(augassign
|
||||
((PLUSEQ))
|
||||
((MINUSEQ))
|
||||
((MULTEQ))
|
||||
((DIVEQ))
|
||||
((MODEQ))
|
||||
((AMPEQ))
|
||||
((OREQ))
|
||||
((HATEQ))
|
||||
((LTLTEQ))
|
||||
((GTGTEQ))
|
||||
((EXPEQ))
|
||||
((DIVDIVEQ)))
|
||||
(del_stmt
|
||||
((DEL exprlist)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(exprlist
|
||||
((expr_list comma_opt)
|
||||
nil))
|
||||
(expr_list
|
||||
((expr)
|
||||
nil)
|
||||
((expr_list COMMA expr)
|
||||
nil))
|
||||
(pass_stmt
|
||||
((PASS)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(flow_stmt
|
||||
((break_stmt))
|
||||
((continue_stmt))
|
||||
((return_stmt))
|
||||
((raise_stmt))
|
||||
((yield_stmt)))
|
||||
(break_stmt
|
||||
((BREAK)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(continue_stmt
|
||||
((CONTINUE)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(return_stmt
|
||||
((RETURN testlist_opt)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(testlist_opt
|
||||
(nil)
|
||||
((testlist)
|
||||
nil))
|
||||
(yield_stmt
|
||||
((YIELD)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil)))
|
||||
((YIELD testlist)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(raise_stmt
|
||||
((RAISE zero_one_two_or_three_tests)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(zero_one_two_or_three_tests
|
||||
(nil)
|
||||
((test zero_one_or_two_tests)
|
||||
nil))
|
||||
(zero_one_or_two_tests
|
||||
(nil)
|
||||
((COMMA test zero_or_one_comma_test)
|
||||
nil))
|
||||
(zero_or_one_comma_test
|
||||
(nil)
|
||||
((COMMA test)
|
||||
nil))
|
||||
(import_stmt
|
||||
((IMPORT dotted_as_name_list)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-include $2 nil)))
|
||||
((FROM dotted_name IMPORT star_or_import_as_name_list)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-include $2 nil))))
|
||||
(dotted_as_name_list
|
||||
((dotted_as_name_list COMMA dotted_as_name)
|
||||
(cons $3 $1))
|
||||
((dotted_as_name)
|
||||
(list $1)))
|
||||
(star_or_import_as_name_list
|
||||
((MULT)
|
||||
nil)
|
||||
((import_as_name_list)
|
||||
nil))
|
||||
(import_as_name_list
|
||||
((import_as_name)
|
||||
nil)
|
||||
((import_as_name_list COMMA import_as_name)
|
||||
nil))
|
||||
(import_as_name
|
||||
((NAME as_name_opt)
|
||||
nil))
|
||||
(dotted_as_name
|
||||
((dotted_name as_name_opt)))
|
||||
(as_name_opt
|
||||
(nil)
|
||||
((AS NAME)
|
||||
(identity $2)))
|
||||
(dotted_name
|
||||
((NAME))
|
||||
((dotted_name PERIOD NAME)
|
||||
(format "%s.%s" $1 $3)))
|
||||
(global_stmt
|
||||
((GLOBAL comma_sep_name_list)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(comma_sep_name_list
|
||||
((NAME))
|
||||
((comma_sep_name_list COMMA NAME)))
|
||||
(exec_stmt
|
||||
((EXEC expr exec_trailer)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(exec_trailer
|
||||
(nil)
|
||||
((IN test comma_test_opt)
|
||||
nil))
|
||||
(comma_test_opt
|
||||
(nil)
|
||||
((COMMA test)
|
||||
nil))
|
||||
(assert_stmt
|
||||
((ASSERT test comma_test_opt)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(compound_stmt
|
||||
((if_stmt))
|
||||
((while_stmt))
|
||||
((for_stmt))
|
||||
((try_stmt))
|
||||
((with_stmt))
|
||||
((funcdef))
|
||||
((class_declaration)))
|
||||
(if_stmt
|
||||
((IF test COLON suite elif_suite_pair_list else_suite_pair_opt)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(elif_suite_pair_list
|
||||
(nil)
|
||||
((elif_suite_pair_list ELIF test COLON suite)
|
||||
nil))
|
||||
(else_suite_pair_opt
|
||||
(nil)
|
||||
((ELSE COLON suite)
|
||||
nil))
|
||||
(suite
|
||||
((simple_stmt)
|
||||
(list $1))
|
||||
((NEWLINE indented_block)
|
||||
(progn $2)))
|
||||
(indented_block
|
||||
((INDENT_BLOCK)
|
||||
(semantic-parse-region
|
||||
(car $region1)
|
||||
(cdr $region1)
|
||||
'indented_block_body 1)))
|
||||
(indented_block_body
|
||||
((INDENT)
|
||||
nil)
|
||||
((DEDENT)
|
||||
nil)
|
||||
((simple_stmt))
|
||||
((compound_stmt)))
|
||||
(while_stmt
|
||||
((WHILE test COLON suite else_suite_pair_opt)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(for_stmt
|
||||
((FOR exprlist IN testlist COLON suite else_suite_pair_opt)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(try_stmt
|
||||
((TRY COLON suite except_clause_suite_pair_list else_suite_pair_opt)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil)))
|
||||
((TRY COLON suite FINALLY COLON suite)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(except_clause_suite_pair_list
|
||||
((except_clause COLON suite)
|
||||
nil)
|
||||
((except_clause_suite_pair_list except_clause COLON suite)
|
||||
nil))
|
||||
(except_clause
|
||||
((EXCEPT zero_one_or_two_test)
|
||||
nil))
|
||||
(zero_one_or_two_test
|
||||
(nil)
|
||||
((test zero_or_one_comma_test)
|
||||
nil))
|
||||
(with_stmt
|
||||
((WITH test COLON suite)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil)))
|
||||
((WITH test with_var COLON suite)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-code $1 nil))))
|
||||
(with_var
|
||||
((AS expr)
|
||||
nil))
|
||||
(decorator
|
||||
((AT dotted_name varargslist_opt NEWLINE)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-function $2 "decorator" $3))))
|
||||
(decorators
|
||||
((decorator)
|
||||
(list $1))
|
||||
((decorator decorators)
|
||||
(cons $1 $2)))
|
||||
(funcdef
|
||||
((DEF NAME function_parameter_list COLON suite)
|
||||
(wisent-python-reconstitute-function-tag
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-function $2 nil $3))
|
||||
$5))
|
||||
((decorators DEF NAME function_parameter_list COLON suite)
|
||||
(wisent-python-reconstitute-function-tag
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-function $3 nil $4 :decorators $1))
|
||||
$6)))
|
||||
(function_parameter_list
|
||||
((PAREN_BLOCK)
|
||||
(let
|
||||
((wisent-python-EXPANDING-block t))
|
||||
(semantic-parse-region
|
||||
(car $region1)
|
||||
(cdr $region1)
|
||||
'function_parameters 1))))
|
||||
(function_parameters
|
||||
((LPAREN)
|
||||
nil)
|
||||
((RPAREN)
|
||||
nil)
|
||||
((function_parameter COMMA))
|
||||
((function_parameter RPAREN)))
|
||||
(function_parameter
|
||||
((fpdef_opt_test))
|
||||
((MULT NAME)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $2 nil nil)))
|
||||
((EXPONENT NAME)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $2 nil nil))))
|
||||
(class_declaration
|
||||
((CLASS NAME paren_class_list_opt COLON suite)
|
||||
(wisent-python-reconstitute-class-tag
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-type $2 $1 $5
|
||||
(cons $3 nil))))))
|
||||
(paren_class_list_opt
|
||||
(nil)
|
||||
((paren_class_list)))
|
||||
(paren_class_list
|
||||
((PAREN_BLOCK)
|
||||
(let
|
||||
((wisent-python-EXPANDING-block t))
|
||||
(mapcar 'semantic-tag-name
|
||||
(semantic-parse-region
|
||||
(car $region1)
|
||||
(cdr $region1)
|
||||
'paren_classes 1)))))
|
||||
(paren_classes
|
||||
((LPAREN)
|
||||
nil)
|
||||
((RPAREN)
|
||||
nil)
|
||||
((paren_class COMMA)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $1 nil nil)))
|
||||
((paren_class RPAREN)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $1 nil nil))))
|
||||
(paren_class
|
||||
((dotted_name)))
|
||||
(test
|
||||
((test_test))
|
||||
((lambdef)))
|
||||
(test_test
|
||||
((and_test))
|
||||
((test_test OR and_test)
|
||||
nil))
|
||||
(and_test
|
||||
((not_test))
|
||||
((and_test AND not_test)
|
||||
nil))
|
||||
(not_test
|
||||
((NOT not_test)
|
||||
nil)
|
||||
((comparison)))
|
||||
(comparison
|
||||
((expr))
|
||||
((comparison comp_op expr)
|
||||
nil))
|
||||
(comp_op
|
||||
((LT))
|
||||
((GT))
|
||||
((EQ))
|
||||
((GE))
|
||||
((LE))
|
||||
((LTGT))
|
||||
((NE))
|
||||
((IN))
|
||||
((NOT IN))
|
||||
((IS))
|
||||
((IS NOT)))
|
||||
(expr
|
||||
((xor_expr))
|
||||
((expr BAR xor_expr)
|
||||
nil))
|
||||
(xor_expr
|
||||
((and_expr))
|
||||
((xor_expr HAT and_expr)
|
||||
nil))
|
||||
(and_expr
|
||||
((shift_expr))
|
||||
((and_expr AMP shift_expr)
|
||||
nil))
|
||||
(shift_expr
|
||||
((arith_expr))
|
||||
((shift_expr shift_expr_operators arith_expr)
|
||||
nil))
|
||||
(shift_expr_operators
|
||||
((LTLT))
|
||||
((GTGT)))
|
||||
(arith_expr
|
||||
((term))
|
||||
((arith_expr plus_or_minus term)
|
||||
nil))
|
||||
(plus_or_minus
|
||||
((PLUS))
|
||||
((MINUS)))
|
||||
(term
|
||||
((factor))
|
||||
((term term_operator factor)
|
||||
nil))
|
||||
(term_operator
|
||||
((MULT))
|
||||
((DIV))
|
||||
((MOD))
|
||||
((DIVDIV)))
|
||||
(factor
|
||||
((prefix_operators factor)
|
||||
nil)
|
||||
((power)))
|
||||
(prefix_operators
|
||||
((PLUS))
|
||||
((MINUS))
|
||||
((TILDE)))
|
||||
(power
|
||||
((atom trailer_zom exponent_zom)
|
||||
(concat $1
|
||||
(if $2
|
||||
(concat " " $2 " ")
|
||||
"")
|
||||
(if $3
|
||||
(concat " " $3)
|
||||
""))))
|
||||
(trailer_zom
|
||||
(nil)
|
||||
((trailer_zom trailer)
|
||||
nil))
|
||||
(exponent_zom
|
||||
(nil)
|
||||
((exponent_zom EXPONENT factor)
|
||||
nil))
|
||||
(trailer
|
||||
((PAREN_BLOCK)
|
||||
nil)
|
||||
((BRACK_BLOCK)
|
||||
nil)
|
||||
((PERIOD NAME)
|
||||
nil))
|
||||
(atom
|
||||
((PAREN_BLOCK)
|
||||
nil)
|
||||
((BRACK_BLOCK)
|
||||
nil)
|
||||
((BRACE_BLOCK)
|
||||
nil)
|
||||
((BACKQUOTE testlist BACKQUOTE)
|
||||
nil)
|
||||
((NAME))
|
||||
((NUMBER_LITERAL))
|
||||
((one_or_more_string)))
|
||||
(test_list_opt
|
||||
(nil)
|
||||
((testlist)
|
||||
nil))
|
||||
(testlist
|
||||
((comma_sep_test_list comma_opt)))
|
||||
(comma_sep_test_list
|
||||
((test))
|
||||
((comma_sep_test_list COMMA test)
|
||||
(format "%s, %s" $1 $3)))
|
||||
(one_or_more_string
|
||||
((STRING_LITERAL))
|
||||
((one_or_more_string STRING_LITERAL)
|
||||
(concat $1 $2)))
|
||||
(lambdef
|
||||
((LAMBDA varargslist_opt COLON test)
|
||||
(format "%s %s" $1
|
||||
(or $2 ""))))
|
||||
(varargslist_opt
|
||||
(nil)
|
||||
((varargslist)))
|
||||
(varargslist
|
||||
((fpdef_opt_test_list_comma_zom rest_args)
|
||||
(nconc $2 $1))
|
||||
((fpdef_opt_test_list comma_opt)))
|
||||
(rest_args
|
||||
((MULT NAME multmult_name_opt)
|
||||
nil)
|
||||
((EXPONENT NAME)
|
||||
nil))
|
||||
(multmult_name_opt
|
||||
(nil)
|
||||
((COMMA EXPONENT NAME)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $3 nil nil))))
|
||||
(fpdef_opt_test_list_comma_zom
|
||||
(nil)
|
||||
((fpdef_opt_test_list_comma_zom fpdef_opt_test COMMA)
|
||||
(nconc $2 $1)))
|
||||
(fpdef_opt_test_list
|
||||
((fpdef_opt_test))
|
||||
((fpdef_opt_test_list COMMA fpdef_opt_test)
|
||||
(nconc $3 $1)))
|
||||
(fpdef_opt_test
|
||||
((fpdef eq_test_opt)))
|
||||
(fpdef
|
||||
((NAME)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $1 nil nil))))
|
||||
(fplist
|
||||
((fpdef_list comma_opt)))
|
||||
(fpdef_list
|
||||
((fpdef))
|
||||
((fpdef_list COMMA fpdef)))
|
||||
(eq_test_opt
|
||||
(nil)
|
||||
((ASSIGN test)
|
||||
nil))
|
||||
(comma_opt
|
||||
(nil)
|
||||
((COMMA)))
|
||||
(semicolon_opt
|
||||
(nil)
|
||||
((SEMICOLON))))
|
||||
'(goal function_parameter paren_class indented_block function_parameters paren_classes indented_block_body)))
|
||||
"Parser table.")
|
||||
|
||||
(defun wisent-python-wy--install-parser ()
|
||||
"Setup the Semantic Parser."
|
||||
(semantic-install-function-overrides
|
||||
'((parse-stream . wisent-parse-stream)))
|
||||
(setq semantic-parser-name "LALR"
|
||||
semantic--parse-table wisent-python-wy--parse-table
|
||||
semantic-debug-parser-source "python.wy"
|
||||
semantic-flex-keywords-obarray wisent-python-wy--keyword-table
|
||||
semantic-lex-types-obarray wisent-python-wy--token-table)
|
||||
;; Collect unmatched syntax lexical tokens
|
||||
(semantic-make-local-hook 'wisent-discarding-token-functions)
|
||||
(add-hook 'wisent-discarding-token-functions
|
||||
'wisent-collect-unmatched-syntax nil t))
|
||||
|
||||
|
||||
;;; Analyzers
|
||||
;;
|
||||
(define-lex-block-type-analyzer wisent-python-wy--<block>-block-analyzer
|
||||
"block analyzer for <block> tokens."
|
||||
"\\s(\\|\\s)"
|
||||
'((("(" LPAREN PAREN_BLOCK)
|
||||
("{" LBRACE BRACE_BLOCK)
|
||||
("[" LBRACK BRACK_BLOCK))
|
||||
(")" RPAREN)
|
||||
("}" RBRACE)
|
||||
("]" RBRACK))
|
||||
)
|
||||
|
||||
(define-lex-regex-type-analyzer wisent-python-wy--<symbol>-regexp-analyzer
|
||||
"regexp analyzer for <symbol> tokens."
|
||||
"\\(\\sw\\|\\s_\\)+"
|
||||
nil
|
||||
'NAME)
|
||||
|
||||
(define-lex-regex-type-analyzer wisent-python-wy--<number>-regexp-analyzer
|
||||
"regexp analyzer for <number> tokens."
|
||||
semantic-lex-number-expression
|
||||
nil
|
||||
'NUMBER_LITERAL)
|
||||
|
||||
(define-lex-string-type-analyzer wisent-python-wy--<punctuation>-string-analyzer
|
||||
"string analyzer for <punctuation> tokens."
|
||||
"\\(\\s.\\|\\s$\\|\\s'\\)+"
|
||||
'((AT . "@")
|
||||
(BACKQUOTE . "`")
|
||||
(ASSIGN . "=")
|
||||
(COMMA . ",")
|
||||
(SEMICOLON . ";")
|
||||
(COLON . ":")
|
||||
(BAR . "|")
|
||||
(TILDE . "~")
|
||||
(PERIOD . ".")
|
||||
(MINUS . "-")
|
||||
(PLUS . "+")
|
||||
(MOD . "%")
|
||||
(DIV . "/")
|
||||
(MULT . "*")
|
||||
(AMP . "&")
|
||||
(GT . ">")
|
||||
(LT . "<")
|
||||
(HAT . "^")
|
||||
(NE . "!=")
|
||||
(LTGT . "<>")
|
||||
(HATEQ . "^=")
|
||||
(OREQ . "|=")
|
||||
(AMPEQ . "&=")
|
||||
(MODEQ . "%=")
|
||||
(DIVEQ . "/=")
|
||||
(MULTEQ . "*=")
|
||||
(MINUSEQ . "-=")
|
||||
(PLUSEQ . "+=")
|
||||
(LE . "<=")
|
||||
(GE . ">=")
|
||||
(EQ . "==")
|
||||
(EXPONENT . "**")
|
||||
(GTGT . ">>")
|
||||
(LTLT . "<<")
|
||||
(DIVDIV . "//")
|
||||
(DIVDIVEQ . "//=")
|
||||
(EXPEQ . "**=")
|
||||
(GTGTEQ . ">>=")
|
||||
(LTLTEQ . "<<="))
|
||||
'punctuation)
|
||||
|
||||
(define-lex-keyword-type-analyzer wisent-python-wy--<keyword>-keyword-analyzer
|
||||
"keyword analyzer for <keyword> tokens."
|
||||
"\\(\\sw\\|\\s_\\)+")
|
||||
|
||||
|
||||
;;; Epilogue
|
||||
;;
|
||||
|
||||
(provide 'semantic/wisent/python-wy)
|
||||
|
||||
;;; semantic/wisent/python-wy.el ends here
|
|
@ -1,306 +0,0 @@
|
|||
;;; srecode/srt-wy.el --- Generated parser support file
|
||||
|
||||
;; Copyright (C) 2005, 2007-2013 Free Software Foundation, Inc.
|
||||
|
||||
;; This file is part of GNU Emacs.
|
||||
|
||||
;; GNU Emacs is free software: you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
;; the Free Software Foundation, either version 3 of the License, or
|
||||
;; (at your option) any later version.
|
||||
|
||||
;; GNU Emacs is distributed in the hope that it will be useful,
|
||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;; GNU General Public License for more details.
|
||||
|
||||
;; You should have received a copy of the GNU General Public License
|
||||
;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
;;; Commentary:
|
||||
;;
|
||||
;; This file was generated from admin/grammars/srecode-template.wy.
|
||||
|
||||
;;; Code:
|
||||
|
||||
(require 'semantic/lex)
|
||||
(eval-when-compile (require 'semantic/bovine))
|
||||
|
||||
;;; Prologue
|
||||
;;
|
||||
|
||||
;;; Declarations
|
||||
;;
|
||||
(defconst srecode-template-wy--keyword-table
|
||||
(semantic-lex-make-keyword-table
|
||||
'(("set" . SET)
|
||||
("show" . SHOW)
|
||||
("macro" . MACRO)
|
||||
("context" . CONTEXT)
|
||||
("template" . TEMPLATE)
|
||||
("sectiondictionary" . SECTIONDICTIONARY)
|
||||
("section" . SECTION)
|
||||
("end" . END)
|
||||
("prompt" . PROMPT)
|
||||
("default" . DEFAULT)
|
||||
("defaultmacro" . DEFAULTMACRO)
|
||||
("read" . READ)
|
||||
("bind" . BIND))
|
||||
'(("bind" summary "bind \"<letter>\"")
|
||||
("read" summary "prompt <symbol> \"Describe Symbol: \" [default[macro] <lispsym>|\"valuetext\"] [read <lispsym>]")
|
||||
("defaultmacro" summary "prompt <symbol> \"Describe Symbol: \" [default[macro] <lispsym>|\"valuetext\"] [read <lispsym>]")
|
||||
("default" summary "prompt <symbol> \"Describe Symbol: \" [default[macro] <lispsym>|\"valuetext\"] [read <lispsym>]")
|
||||
("prompt" summary "prompt <symbol> \"Describe Symbol: \" [default[macro] <lispsym>|\"valuetext\"] [read <lispsym>]")
|
||||
("end" summary "section ... end")
|
||||
("section" summary "section <name>\\n <dictionary entries>\\n end")
|
||||
("sectiondictionary" summary "sectiondictionary <name>\\n <dictionary entries>")
|
||||
("template" summary "template <name>\\n <template definition>")
|
||||
("context" summary "context <name>")
|
||||
("macro" summary "... macro \"string\" ...")
|
||||
("show" summary "show <name> ; to show a section")
|
||||
("set" summary "set <name> <value>")))
|
||||
"Table of language keywords.")
|
||||
|
||||
(defconst srecode-template-wy--token-table
|
||||
(semantic-lex-make-type-table
|
||||
'(("number"
|
||||
(number))
|
||||
("string"
|
||||
(string))
|
||||
("symbol"
|
||||
(symbol))
|
||||
("property"
|
||||
(property))
|
||||
("separator"
|
||||
(TEMPLATE_BLOCK . "^----"))
|
||||
("newline"
|
||||
(newline)))
|
||||
'(("number" :declared t)
|
||||
("string" :declared t)
|
||||
("symbol" :declared t)
|
||||
("property" syntax ":\\(\\w\\|\\s_\\)*")
|
||||
("property" :declared t)
|
||||
("newline" :declared t)
|
||||
("punctuation" syntax "\\s.+")
|
||||
("punctuation" :declared t)
|
||||
("keyword" :declared t)))
|
||||
"Table of lexical tokens.")
|
||||
|
||||
(defconst srecode-template-wy--parse-table
|
||||
(progn
|
||||
(eval-when-compile
|
||||
(require 'semantic/wisent/comp))
|
||||
(wisent-compile-grammar
|
||||
'((SET SHOW MACRO CONTEXT TEMPLATE SECTIONDICTIONARY SECTION END PROMPT DEFAULT DEFAULTMACRO READ BIND newline TEMPLATE_BLOCK property symbol string number)
|
||||
nil
|
||||
(template_file
|
||||
((newline)
|
||||
nil)
|
||||
((context))
|
||||
((prompt))
|
||||
((variable))
|
||||
((template)))
|
||||
(context
|
||||
((CONTEXT symbol newline)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag $2 'context))))
|
||||
(prompt
|
||||
((PROMPT symbol string opt-default-fcn opt-read-fcn newline)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag $2 'prompt :text
|
||||
(read $3)
|
||||
:default $4 :read $5))))
|
||||
(opt-default-fcn
|
||||
((DEFAULT symbol)
|
||||
(progn
|
||||
(read $2)))
|
||||
((DEFAULT string)
|
||||
(progn
|
||||
(read $2)))
|
||||
((DEFAULTMACRO string)
|
||||
(progn
|
||||
(cons 'macro
|
||||
(read $2))))
|
||||
(nil nil))
|
||||
(opt-read-fcn
|
||||
((READ symbol)
|
||||
(progn
|
||||
(read $2)))
|
||||
(nil nil))
|
||||
(variable
|
||||
((SET symbol insertable-string-list newline)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $2 nil $3)))
|
||||
((SET symbol number newline)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $2 nil
|
||||
(list $3))))
|
||||
((SHOW symbol newline)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-variable $2 nil t))))
|
||||
(insertable-string-list
|
||||
((insertable-string)
|
||||
(list $1))
|
||||
((insertable-string-list insertable-string)
|
||||
(append $1
|
||||
(list $2))))
|
||||
(insertable-string
|
||||
((string)
|
||||
(read $1))
|
||||
((MACRO string)
|
||||
(cons 'macro
|
||||
(read $2))))
|
||||
(template
|
||||
((TEMPLATE templatename opt-dynamic-arguments newline opt-string section-dictionary-list TEMPLATE_BLOCK newline opt-bind)
|
||||
(wisent-raw-tag
|
||||
(semantic-tag-new-function $2 nil $3 :documentation $5 :code $7 :dictionaries $6 :binding $9))))
|
||||
(templatename
|
||||
((symbol))
|
||||
((PROMPT))
|
||||
((CONTEXT))
|
||||
((TEMPLATE))
|
||||
((DEFAULT))
|
||||
((MACRO))
|
||||
((DEFAULTMACRO))
|
||||
((READ))
|
||||
((SET)))
|
||||
(opt-dynamic-arguments
|
||||
((property opt-dynamic-arguments)
|
||||
(cons $1 $2))
|
||||
(nil nil))
|
||||
(opt-string
|
||||
((string newline)
|
||||
(read $1))
|
||||
(nil nil))
|
||||
(section-dictionary-list
|
||||
(nil nil)
|
||||
((section-dictionary-list flat-section-dictionary)
|
||||
(append $1
|
||||
(list $2)))
|
||||
((section-dictionary-list section-dictionary)
|
||||
(append $1
|
||||
(list $2))))
|
||||
(flat-section-dictionary
|
||||
((SECTIONDICTIONARY string newline flat-dictionary-entry-list)
|
||||
(cons
|
||||
(read $2)
|
||||
$4)))
|
||||
(flat-dictionary-entry-list
|
||||
(nil nil)
|
||||
((flat-dictionary-entry-list flat-dictionary-entry)
|
||||
(append $1 $2)))
|
||||
(flat-dictionary-entry
|
||||
((variable)
|
||||
(wisent-cook-tag $1)))
|
||||
(section-dictionary
|
||||
((SECTION string newline dictionary-entry-list END newline)
|
||||
(cons
|
||||
(read $2)
|
||||
$4)))
|
||||
(dictionary-entry-list
|
||||
(nil nil)
|
||||
((dictionary-entry-list dictionary-entry)
|
||||
(append $1 $2)))
|
||||
(dictionary-entry
|
||||
((variable)
|
||||
(wisent-cook-tag $1))
|
||||
((section-dictionary)
|
||||
(list $1)))
|
||||
(opt-bind
|
||||
((BIND string newline)
|
||||
(read $2))
|
||||
(nil nil)))
|
||||
'(template_file)))
|
||||
"Parser table.")
|
||||
|
||||
(defun srecode-template-wy--install-parser ()
|
||||
"Setup the Semantic Parser."
|
||||
(semantic-install-function-overrides
|
||||
'((parse-stream . wisent-parse-stream)))
|
||||
(setq semantic-parser-name "LALR"
|
||||
semantic--parse-table srecode-template-wy--parse-table
|
||||
semantic-debug-parser-source "srecode-template.wy"
|
||||
semantic-flex-keywords-obarray srecode-template-wy--keyword-table
|
||||
semantic-lex-types-obarray srecode-template-wy--token-table)
|
||||
;; Collect unmatched syntax lexical tokens
|
||||
(semantic-make-local-hook 'wisent-discarding-token-functions)
|
||||
(add-hook 'wisent-discarding-token-functions
|
||||
'wisent-collect-unmatched-syntax nil t))
|
||||
|
||||
|
||||
;;; Analyzers
|
||||
;;
|
||||
(define-lex-regex-type-analyzer srecode-template-wy--<property>-regexp-analyzer
|
||||
"regexp analyzer for <property> tokens."
|
||||
":\\(\\w\\|\\s_\\)*"
|
||||
nil
|
||||
'property)
|
||||
|
||||
(define-lex-regex-type-analyzer srecode-template-wy--<symbol>-regexp-analyzer
|
||||
"regexp analyzer for <symbol> tokens."
|
||||
"\\(\\sw\\|\\s_\\)+"
|
||||
nil
|
||||
'symbol)
|
||||
|
||||
(define-lex-regex-type-analyzer srecode-template-wy--<number>-regexp-analyzer
|
||||
"regexp analyzer for <number> tokens."
|
||||
semantic-lex-number-expression
|
||||
nil
|
||||
'number)
|
||||
|
||||
(define-lex-string-type-analyzer srecode-template-wy--<punctuation>-string-analyzer
|
||||
"string analyzer for <punctuation> tokens."
|
||||
"\\s.+"
|
||||
nil
|
||||
'punctuation)
|
||||
|
||||
(define-lex-sexp-type-analyzer srecode-template-wy--<string>-sexp-analyzer
|
||||
"sexp analyzer for <string> tokens."
|
||||
"\\s\""
|
||||
'string)
|
||||
|
||||
(define-lex-keyword-type-analyzer srecode-template-wy--<keyword>-keyword-analyzer
|
||||
"keyword analyzer for <keyword> tokens."
|
||||
"\\(\\sw\\|\\s_\\)+")
|
||||
|
||||
|
||||
;;; Epilogue
|
||||
;;
|
||||
(define-lex-simple-regex-analyzer srecode-template-property-analyzer
|
||||
"Detect and create a dynamic argument properties."
|
||||
":\\(\\w\\|\\s_\\)*" 'property 0)
|
||||
|
||||
(define-lex-regex-analyzer srecode-template-separator-block
|
||||
"Detect and create a template quote block."
|
||||
"^----\n"
|
||||
(semantic-lex-push-token
|
||||
(semantic-lex-token
|
||||
'TEMPLATE_BLOCK
|
||||
(match-end 0)
|
||||
(semantic-lex-unterminated-syntax-protection 'TEMPLATE_BLOCK
|
||||
(goto-char (match-end 0))
|
||||
(re-search-forward "^----$")
|
||||
(match-beginning 0))))
|
||||
(setq semantic-lex-end-point (point)))
|
||||
|
||||
|
||||
(define-lex wisent-srecode-template-lexer
|
||||
"Lexical analyzer that handles SRecode Template buffers.
|
||||
It ignores whitespace, newlines and comments."
|
||||
semantic-lex-newline
|
||||
semantic-lex-ignore-whitespace
|
||||
semantic-lex-ignore-newline
|
||||
semantic-lex-ignore-comments
|
||||
srecode-template-separator-block
|
||||
srecode-template-wy--<keyword>-keyword-analyzer
|
||||
srecode-template-property-analyzer
|
||||
srecode-template-wy--<number>-regexp-analyzer
|
||||
srecode-template-wy--<symbol>-regexp-analyzer
|
||||
srecode-template-wy--<string>-sexp-analyzer
|
||||
srecode-template-wy--<punctuation>-string-analyzer
|
||||
semantic-lex-default-action
|
||||
)
|
||||
|
||||
(provide 'srecode/srt-wy)
|
||||
|
||||
;;; srecode/srt-wy.el ends here
|
|
@ -752,6 +752,7 @@ See `make-comint' and `comint-exec'."
|
|||
(let ((name (file-name-nondirectory program)))
|
||||
(switch-to-buffer (make-comint name program))
|
||||
(run-hooks (intern-soft (concat "comint-" name "-hook")))))
|
||||
(put 'comint-run 'interactive-only 'make-comint)
|
||||
|
||||
(defun comint-exec (buffer name command startfile switches)
|
||||
"Start up a process named NAME in buffer BUFFER for Comint modes.
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
;;; composite.el --- support character composition
|
||||
|
||||
;; Copyright (C) 2001-2013 Free Software Foundation, Inc.
|
||||
|
||||
;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
|
||||
;; 2008, 2009, 2010, 2011
|
||||
;; National Institute of Advanced Industrial Science and Technology (AIST)
|
||||
|
@ -669,13 +671,15 @@ All non-spacing characters have this function in
|
|||
(setq i (1+ i))))
|
||||
gstring))))))
|
||||
|
||||
(let ((elt `([,(purecopy "\\c.\\c^+") 1 compose-gstring-for-graphic]
|
||||
[nil 0 compose-gstring-for-graphic])))
|
||||
(map-char-table
|
||||
#'(lambda (key val)
|
||||
(if (memq val '(Mn Mc Me))
|
||||
(set-char-table-range composition-function-table key elt)))
|
||||
unicode-category-table))
|
||||
;; Allow for bootstrapping without uni-*.el.
|
||||
(when unicode-category-table
|
||||
(let ((elt `([,(purecopy "\\c.\\c^+") 1 compose-gstring-for-graphic]
|
||||
[nil 0 compose-gstring-for-graphic])))
|
||||
(map-char-table
|
||||
#'(lambda (key val)
|
||||
(if (memq val '(Mn Mc Me))
|
||||
(set-char-table-range composition-function-table key elt)))
|
||||
unicode-category-table)))
|
||||
|
||||
(defun compose-gstring-for-terminal (gstring)
|
||||
"Compose glyph-string GSTRING for terminal display.
|
||||
|
|
|
@ -272,6 +272,7 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of
|
|||
(tool-bar-mode (frames mouse) boolean nil
|
||||
; :initialize custom-initialize-default
|
||||
:set custom-set-minor-mode)
|
||||
(frame-resize-pixelwise windows boolean "24.4")
|
||||
;; fringe.c
|
||||
(overflow-newline-into-fringe fringe boolean)
|
||||
;; image.c
|
||||
|
@ -448,6 +449,7 @@ since it could result in memory overflow and make Emacs crash."
|
|||
:value display-buffer)
|
||||
(other :tag "Always (t)" :value t))
|
||||
"24.3")
|
||||
(window-resize-pixelwise windows boolean "24.4")
|
||||
;; xdisp.c
|
||||
;; The whitespace group is for whitespace.el.
|
||||
(show-trailing-whitespace editing-basics boolean nil
|
||||
|
|
|
@ -499,6 +499,7 @@ Typically \"page-%s.png\".")
|
|||
;; how many pages will be available.
|
||||
(null doc-view--current-converter-processes))
|
||||
(setq page len)))
|
||||
(force-mode-line-update) ;To update `current-page'.
|
||||
(setf (doc-view-current-page) page
|
||||
(doc-view-current-info)
|
||||
(concat
|
||||
|
|
|
@ -284,6 +284,8 @@ This is a global minor mode. When enabled, it reindents whenever
|
|||
the hook `electric-indent-functions' returns non-nil, or you
|
||||
insert a character from `electric-indent-chars'."
|
||||
:global t :group 'electricity
|
||||
:initialize 'custom-initialize-delay
|
||||
:init-value t
|
||||
(if (not electric-indent-mode)
|
||||
(progn
|
||||
(when (eq (lookup-key global-map [?\C-j])
|
||||
|
|
|
@ -617,6 +617,7 @@ in the repository.")
|
|||
("config.h.in" . "config.in")
|
||||
("paths.h-dist" . "paths.h.in")
|
||||
("patch1" . "sed1.inp")
|
||||
("enriched.doc" . "enriched.txt")
|
||||
("GETTING.GNU.SOFTWARE" . "FTP")
|
||||
("etc/MACHINES" . "MACHINES")
|
||||
("ONEWS" . "NEWS.19")
|
||||
|
|
|
@ -112,10 +112,10 @@ to set this property.")
|
|||
''edebug-form-spec (list 'quote spec)))))
|
||||
defun-declarations-alist)
|
||||
"List associating properties of macros to their macro expansion.
|
||||
Each element of the list takes the form (PROP FUN) where FUN is
|
||||
a function. For each (PROP . VALUES) in a macro's declaration,
|
||||
the FUN corresponding to PROP is called with the function name
|
||||
and the VALUES and should return the code to use to set this property.")
|
||||
Each element of the list takes the form (PROP FUN) where FUN is a function.
|
||||
For each (PROP . VALUES) in a macro's declaration, the FUN corresponding
|
||||
to PROP is called with the macro name, the macro's arglist, and the VALUES
|
||||
and should return the code to use to set this property.")
|
||||
|
||||
(put 'defmacro 'doc-string-elt 3)
|
||||
(put 'defmacro 'lisp-indent-function 2)
|
||||
|
@ -285,7 +285,6 @@ was first made obsolete, for example a date or a release number."
|
|||
(declare (advertised-calling-convention
|
||||
;; New code should always provide the `when' argument.
|
||||
(obsolete-name current-name when) "23.1"))
|
||||
(interactive "aMake function obsolete: \nxObsoletion replacement: ")
|
||||
(put obsolete-name 'byte-obsolete-info
|
||||
;; The second entry used to hold the `byte-compile' handler, but
|
||||
;; is not used any more nowadays.
|
||||
|
@ -392,7 +391,7 @@ If you think you need this, you're probably making a mistake somewhere."
|
|||
"Like `progn', but evaluates the body at compile time if you're compiling.
|
||||
Thus, the result of the body appears to the compiler as a quoted constant.
|
||||
In interpreted code, this is entirely equivalent to `progn'."
|
||||
(declare (debug t) (indent 0))
|
||||
(declare (debug (def-body)) (indent 0))
|
||||
(list 'quote (eval (cons 'progn body) lexical-binding)))
|
||||
|
||||
(defmacro eval-and-compile (&rest body)
|
||||
|
|
|
@ -353,11 +353,11 @@ else the global value will be modified."
|
|||
(t
|
||||
(append byte-compile-warnings (list warning)))))))
|
||||
|
||||
(defvar byte-compile-interactive-only-functions
|
||||
'(beginning-of-buffer end-of-buffer replace-string replace-regexp
|
||||
insert-file insert-buffer insert-file-literally previous-line next-line
|
||||
goto-line comint-run delete-backward-char)
|
||||
(defvar byte-compile-interactive-only-functions nil
|
||||
"List of commands that are not meant to be called from Lisp.")
|
||||
(make-obsolete-variable 'byte-compile-interactive-only-functions
|
||||
"use the `interactive-only' symbol property instead"
|
||||
"24.4")
|
||||
|
||||
(defvar byte-compile-not-obsolete-vars nil
|
||||
"List of variables that shouldn't be reported as obsolete.")
|
||||
|
@ -2929,13 +2929,23 @@ for symbols generated by the byte compiler itself."
|
|||
(byte-compile-variable-ref form))))
|
||||
((symbolp (car form))
|
||||
(let* ((fn (car form))
|
||||
(handler (get fn 'byte-compile)))
|
||||
(handler (get fn 'byte-compile))
|
||||
(interactive-only
|
||||
(or (get fn 'interactive-only)
|
||||
(memq fn byte-compile-interactive-only-functions))))
|
||||
(when (macroexp--const-symbol-p fn)
|
||||
(byte-compile-warn "`%s' called as a function" fn))
|
||||
(and (byte-compile-warning-enabled-p 'interactive-only)
|
||||
(memq fn byte-compile-interactive-only-functions)
|
||||
(byte-compile-warn "`%s' used from Lisp code\n\
|
||||
That command is designed for interactive use only" fn))
|
||||
(when (and (byte-compile-warning-enabled-p 'interactive-only)
|
||||
interactive-only)
|
||||
(byte-compile-warn "`%s' is for interactive use only%s"
|
||||
fn
|
||||
(cond ((stringp interactive-only)
|
||||
(format "; %s" interactive-only))
|
||||
((and (symbolp 'interactive-only)
|
||||
(not (eq interactive-only t)))
|
||||
(format "; use `%s' instead."
|
||||
interactive-only))
|
||||
(t "."))))
|
||||
(if (and (fboundp (car form))
|
||||
(eq (car-safe (symbol-function (car form))) 'macro))
|
||||
(byte-compile-log-warning
|
||||
|
@ -3598,7 +3608,7 @@ discarding."
|
|||
(byte-compile-constant (if (eq 'lambda (car-safe f))
|
||||
(byte-compile-lambda f)
|
||||
f))))
|
||||
|
||||
|
||||
(defun byte-compile-indent-to (form)
|
||||
(let ((len (length form)))
|
||||
(cond ((= len 2)
|
||||
|
|
|
@ -204,7 +204,7 @@ first will be printed into the backtrace buffer."
|
|||
(window-resize
|
||||
debugger-window
|
||||
(- debugger-previous-window-height
|
||||
(window-total-size debugger-window)))
|
||||
(window-total-height debugger-window)))
|
||||
(error nil)))
|
||||
(setq debugger-previous-window debugger-window))
|
||||
(debugger-mode)
|
||||
|
@ -236,7 +236,7 @@ first will be printed into the backtrace buffer."
|
|||
(eq (window-buffer debugger-window) debugger-buffer))
|
||||
;; Record height of debugger window.
|
||||
(setq debugger-previous-window-height
|
||||
(window-total-size debugger-window)))
|
||||
(window-total-height debugger-window)))
|
||||
(if debugger-will-be-back
|
||||
;; Restore previous window configuration (Bug#12623).
|
||||
(set-window-configuration window-configuration)
|
||||
|
@ -494,9 +494,13 @@ removes itself from that hook."
|
|||
(forward-line 1)
|
||||
(while (progn
|
||||
(forward-char 2)
|
||||
(if (= (following-char) ?\()
|
||||
(forward-sexp 1)
|
||||
(forward-sexp 2))
|
||||
(cond ((debugger--locals-visible-p)
|
||||
(goto-char (next-single-char-property-change
|
||||
(point) 'locals-visible)))
|
||||
((= (following-char) ?\()
|
||||
(forward-sexp 1))
|
||||
(t
|
||||
(forward-sexp 2)))
|
||||
(forward-line 1)
|
||||
(<= (point) opoint))
|
||||
(if (looking-at " *;;;")
|
||||
|
@ -541,6 +545,14 @@ Applies to the frame whose line point is on in the backtrace."
|
|||
(progn ,@body)
|
||||
(setq debugger-outer-match-data (match-data)))))
|
||||
|
||||
(defun debugger--backtrace-base ()
|
||||
"Return the function name that marks the top of the backtrace.
|
||||
See `backtrace-frame'."
|
||||
(cond ((eq 'debug--implement-debug-on-entry
|
||||
(cadr (backtrace-frame 1 'debug)))
|
||||
'debug--implement-debug-on-entry)
|
||||
(t 'debug)))
|
||||
|
||||
(defun debugger-eval-expression (exp &optional nframe)
|
||||
"Eval an expression, in an environment like that outside the debugger.
|
||||
The environment used is the one when entering the activation frame at point."
|
||||
|
@ -549,15 +561,70 @@ The environment used is the one when entering the activation frame at point."
|
|||
(let ((nframe (or nframe
|
||||
(condition-case nil (1+ (debugger-frame-number 'skip-base))
|
||||
(error 0)))) ;; If on first line.
|
||||
(base (if (eq 'debug--implement-debug-on-entry
|
||||
(cadr (backtrace-frame 1 'debug)))
|
||||
'debug--implement-debug-on-entry 'debug)))
|
||||
(base (debugger--backtrace-base)))
|
||||
(debugger-env-macro
|
||||
(let ((val (backtrace-eval exp nframe base)))
|
||||
(prog1
|
||||
(prin1 val t)
|
||||
(let ((str (eval-expression-print-format val)))
|
||||
(if str (princ str t))))))))
|
||||
|
||||
(defun debugger--locals-visible-p ()
|
||||
"Are the local variables of the current stack frame visible?"
|
||||
(save-excursion
|
||||
(move-to-column 2)
|
||||
(get-text-property (point) 'locals-visible)))
|
||||
|
||||
(defun debugger--insert-locals (locals)
|
||||
"Insert the local variables LOCALS at point."
|
||||
(cond ((null locals)
|
||||
(insert "\n [no locals]"))
|
||||
(t
|
||||
(let ((print-escape-newlines t))
|
||||
(dolist (s+v locals)
|
||||
(let ((symbol (car s+v))
|
||||
(value (cdr s+v)))
|
||||
(insert "\n ")
|
||||
(prin1 symbol (current-buffer))
|
||||
(insert " = ")
|
||||
(prin1 value (current-buffer))))))))
|
||||
|
||||
(defun debugger--show-locals ()
|
||||
"For the frame at point, insert locals and add text properties."
|
||||
(let* ((nframe (1+ (debugger-frame-number 'skip-base)))
|
||||
(base (debugger--backtrace-base))
|
||||
(locals (backtrace--locals nframe base))
|
||||
(inhibit-read-only t))
|
||||
(save-excursion
|
||||
(let ((start (progn
|
||||
(move-to-column 2)
|
||||
(point))))
|
||||
(end-of-line)
|
||||
(debugger--insert-locals locals)
|
||||
(add-text-properties start (point) '(locals-visible t))))))
|
||||
|
||||
(defun debugger--hide-locals ()
|
||||
"Delete local variables and remove the text property."
|
||||
(let* ((col (current-column))
|
||||
(end (progn
|
||||
(move-to-column 2)
|
||||
(next-single-char-property-change (point) 'locals-visible)))
|
||||
(start (previous-single-char-property-change end 'locals-visible))
|
||||
(inhibit-read-only t))
|
||||
(remove-text-properties start end '(locals-visible))
|
||||
(goto-char start)
|
||||
(end-of-line)
|
||||
(delete-region (point) end)
|
||||
(move-to-column col)))
|
||||
|
||||
(defun debugger-toggle-locals ()
|
||||
"Show or hide local variables of the current stack frame."
|
||||
(interactive)
|
||||
(cond ((debugger--locals-visible-p)
|
||||
(debugger--hide-locals))
|
||||
(t
|
||||
(debugger--show-locals))))
|
||||
|
||||
|
||||
(defvar debugger-mode-map
|
||||
(let ((map (make-keymap))
|
||||
|
@ -575,6 +642,7 @@ The environment used is the one when entering the activation frame at point."
|
|||
(define-key map "h" 'describe-mode)
|
||||
(define-key map "q" 'top-level)
|
||||
(define-key map "e" 'debugger-eval-expression)
|
||||
(define-key map "v" 'debugger-toggle-locals) ;"v" is for "v"ariables.
|
||||
(define-key map " " 'next-line)
|
||||
(define-key map "R" 'debugger-record-expression)
|
||||
(define-key map "\C-m" 'debug-help-follow)
|
||||
|
|
|
@ -216,6 +216,9 @@ expression point is on."
|
|||
Otherwise work like `message'."
|
||||
(if (minibufferp)
|
||||
(progn
|
||||
(add-hook 'minibuffer-exit-hook
|
||||
(lambda () (setq eldoc-mode-line-string nil))
|
||||
nil t)
|
||||
(with-current-buffer
|
||||
(window-buffer
|
||||
(or (window-in-direction 'above (minibuffer-window))
|
||||
|
@ -226,17 +229,11 @@ Otherwise work like `message'."
|
|||
(setq mode-line-format
|
||||
(list "" '(eldoc-mode-line-string
|
||||
(" " eldoc-mode-line-string " "))
|
||||
mode-line-format))))
|
||||
(add-hook 'minibuffer-exit-hook
|
||||
(lambda () (setq eldoc-mode-line-string nil))
|
||||
nil t)
|
||||
(cond
|
||||
((null format-string)
|
||||
(setq eldoc-mode-line-string nil))
|
||||
((stringp format-string)
|
||||
(setq eldoc-mode-line-string
|
||||
(apply 'format format-string args))))
|
||||
(force-mode-line-update))
|
||||
mode-line-format)))
|
||||
(setq eldoc-mode-line-string
|
||||
(when (stringp format-string)
|
||||
(apply 'format format-string args)))
|
||||
(force-mode-line-update)))
|
||||
(apply 'message format-string args)))
|
||||
|
||||
(defun eldoc-message (&rest args)
|
||||
|
|
|
@ -37,6 +37,38 @@
|
|||
(maphash (lambda (_k v) (push v values)) hash-table)
|
||||
values))
|
||||
|
||||
(defsubst string-empty-p (string)
|
||||
"Check whether STRING is empty."
|
||||
(string= string ""))
|
||||
|
||||
(defsubst string-join (strings &optional separator)
|
||||
"Join all STRINGS using SEPARATOR."
|
||||
(mapconcat 'identity strings separator))
|
||||
|
||||
(defsubst string-reverse (str)
|
||||
"Reverse the string STR."
|
||||
(apply 'string (nreverse (string-to-list str))))
|
||||
|
||||
(defsubst string-trim-left (string)
|
||||
"Remove leading whitespace from STRING."
|
||||
(if (string-match "\\`[ \t\n\r]+" string)
|
||||
(replace-match "" t t string)
|
||||
string))
|
||||
|
||||
(defsubst string-trim-right (string)
|
||||
"Remove trailing whitespace from STRING."
|
||||
(if (string-match "[ \t\n\r]+\\'" string)
|
||||
(replace-match "" t t string)
|
||||
string))
|
||||
|
||||
(defsubst string-trim (string)
|
||||
"Remove leading and trailing whitespace from STRING."
|
||||
(string-trim-left (string-trim-right string)))
|
||||
|
||||
(defsubst string-blank-p (string)
|
||||
"Check whether STRING is either empty or only whitespace."
|
||||
(string-empty-p (string-trim string)))
|
||||
|
||||
(provide 'helpers)
|
||||
|
||||
;;; helpers.el ends here
|
||||
|
|
|
@ -461,8 +461,8 @@ each line."
|
|||
(let ((keywords (lm-keywords file)))
|
||||
(if keywords
|
||||
(if (string-match-p "," keywords)
|
||||
(split-string keywords ",[ \t\n]*" t)
|
||||
(split-string keywords "[ \t\n]+" t)))))
|
||||
(split-string keywords ",[ \t\n]*" t "[ ]+")
|
||||
(split-string keywords "[ \t\n]+" t "[ ]+")))))
|
||||
|
||||
(defvar finder-known-keywords)
|
||||
(defun lm-keywords-finder-p (&optional file)
|
||||
|
|
|
@ -1403,6 +1403,8 @@ If optional arg NO-ACTIVATE is non-nil, don't activate packages."
|
|||
'action 'package-install-button-action)))
|
||||
(t (insert (capitalize status) ".")))
|
||||
(insert "\n")
|
||||
(insert " " (propertize "Archive" 'font-lock-face 'bold)
|
||||
": " (or archive "n/a") "\n")
|
||||
(and version
|
||||
(insert " "
|
||||
(propertize "Version" 'font-lock-face 'bold) ": "
|
||||
|
|
|
@ -285,7 +285,9 @@ CHARS should be a list of characters."
|
|||
;;
|
||||
;; Make sure a caret is not first and a dash is first or last.
|
||||
(if (and (string-equal charset "") (string-equal bracket ""))
|
||||
(concat "[" dash caret "]")
|
||||
(if (string-equal dash "")
|
||||
"\\^" ; [^] is not a valid regexp
|
||||
(concat "[" dash caret "]"))
|
||||
(concat "[" bracket charset caret dash "]"))))
|
||||
|
||||
(provide 'regexp-opt)
|
||||
|
|
|
@ -109,8 +109,7 @@ Internal use only.")
|
|||
|
||||
(defun emacs-lock-live-process-p (buffer-or-name)
|
||||
"Return t if BUFFER-OR-NAME is associated with a live process."
|
||||
(let ((proc (get-buffer-process buffer-or-name)))
|
||||
(and proc (process-live-p proc))))
|
||||
(process-live-p (get-buffer-process buffer-or-name)))
|
||||
|
||||
(defun emacs-lock--can-auto-unlock (action)
|
||||
"Return t if the current buffer can auto-unlock for ACTION.
|
||||
|
|
|
@ -132,6 +132,7 @@ encryption is used."
|
|||
(error)))
|
||||
(local-file (or local-copy file))
|
||||
(context (epg-make-context))
|
||||
(buf (current-buffer))
|
||||
string length entry)
|
||||
(if visit
|
||||
(setq buffer-file-name file))
|
||||
|
@ -157,16 +158,16 @@ encryption is used."
|
|||
;; where `find-file-not-found-functions' are called in
|
||||
;; `find-file-noselect-1'.
|
||||
(when (file-exists-p local-file)
|
||||
(make-local-variable 'epa-file-error)
|
||||
(setq epa-file-error error)
|
||||
(setq-local epa-file-error error)
|
||||
(add-hook 'find-file-not-found-functions
|
||||
'epa-file--find-file-not-found-function
|
||||
nil t))
|
||||
(signal 'file-error
|
||||
(cons "Opening input file" (cdr error)))))
|
||||
(make-local-variable 'epa-file-encrypt-to)
|
||||
(setq epa-file-encrypt-to
|
||||
(mapcar #'car (epg-context-result-for context 'encrypted-to)))
|
||||
(set-buffer buf) ;In case timer/filter changed/killed it (bug#16029)!
|
||||
(setq-local epa-file-encrypt-to
|
||||
(mapcar #'car (epg-context-result-for
|
||||
context 'encrypted-to)))
|
||||
(if (or beg end)
|
||||
(setq string (substring string (or beg 0) end)))
|
||||
(save-excursion
|
||||
|
@ -268,14 +269,13 @@ If no one is selected, symmetric encryption will be performed. "
|
|||
(defun epa-file-select-keys ()
|
||||
"Select recipients for encryption."
|
||||
(interactive)
|
||||
(make-local-variable 'epa-file-encrypt-to)
|
||||
(setq epa-file-encrypt-to
|
||||
(mapcar
|
||||
(lambda (key)
|
||||
(epg-sub-key-id (car (epg-key-sub-key-list key))))
|
||||
(epa-select-keys
|
||||
(epg-make-context)
|
||||
"Select recipients for encryption.
|
||||
(setq-local epa-file-encrypt-to
|
||||
(mapcar
|
||||
(lambda (key)
|
||||
(epg-sub-key-id (car (epg-key-sub-key-list key))))
|
||||
(epa-select-keys
|
||||
(epg-make-context)
|
||||
"Select recipients for encryption.
|
||||
If no one is selected, symmetric encryption will be performed. "))))
|
||||
|
||||
;;;###autoload
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2013-11-25 Glenn Morris <rgm@gnu.org>
|
||||
|
||||
* erc-button.el (erc-nick-popup): Make `nick' available in the
|
||||
eval environment. (Bug#15969)
|
||||
|
||||
2013-11-04 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* erc-pcomplete.el (erc-pcomplete): Set this-command.
|
||||
|
|
|
@ -514,7 +514,7 @@ Examples:
|
|||
(code (cdr (assoc action erc-nick-popup-alist))))
|
||||
(when code
|
||||
(erc-set-active-buffer (current-buffer))
|
||||
(eval code))))
|
||||
(eval code `((nick . ,nick))))))
|
||||
|
||||
;;; Callback functions
|
||||
(defun erc-button-describe-symbol (symbol-name)
|
||||
|
|
|
@ -207,7 +207,7 @@ include the following symbols:
|
|||
permissions or modification time
|
||||
|
||||
If FILE is a directory, 'change' watches for file creation or
|
||||
deletion in that directory.
|
||||
deletion in that directory. This does not work recursively.
|
||||
|
||||
When any event happens, Emacs will call the CALLBACK function passing
|
||||
it a single argument EVENT, which is of the form
|
||||
|
@ -237,8 +237,7 @@ FILE is the name of the file whose event is being reported."
|
|||
|
||||
(let* ((handler (find-file-name-handler file 'file-notify-add-watch))
|
||||
(dir (directory-file-name
|
||||
(if (or (and (not handler) (eq file-notify--library 'w32notify))
|
||||
(file-directory-p file))
|
||||
(if (file-directory-p file)
|
||||
file
|
||||
(file-name-directory file))))
|
||||
desc func l-flags)
|
||||
|
|
|
@ -2085,6 +2085,7 @@ Don't call it from programs! Use `insert-file-contents-literally' instead.
|
|||
\(Its calling sequence is different; see its documentation)."
|
||||
(interactive "*fInsert file literally: ")
|
||||
(insert-file-1 filename #'insert-file-contents-literally))
|
||||
(put 'insert-file-literally 'interactive-only 'insert-file-contents-literally)
|
||||
|
||||
(defvar find-file-literally nil
|
||||
"Non-nil if this buffer was made by `find-file-literally' or equivalent.
|
||||
|
@ -5007,6 +5008,7 @@ Don't call it from programs! Use `insert-file-contents' instead.
|
|||
\(Its calling sequence is different; see its documentation)."
|
||||
(interactive "*fInsert file: ")
|
||||
(insert-file-1 filename #'insert-file-contents))
|
||||
(put 'insert-file 'interactive-only 'insert-file-contents)
|
||||
|
||||
(defun append-to-file (start end filename)
|
||||
"Append the contents of the region to the end of file FILENAME.
|
||||
|
|
|
@ -120,6 +120,23 @@ appended when the minibuffer frame is created."
|
|||
(delete-frame frame t)
|
||||
;; Gildea@x.org says it is ok to ask questions before terminating.
|
||||
(save-buffers-kill-emacs))))
|
||||
|
||||
(defun handle-focus-in (_event)
|
||||
"Handle a focus-in event.
|
||||
Focus-in events are usually bound to this function.
|
||||
Focus-in events occur when a frame has focus, but a switch-frame event
|
||||
is not generated.
|
||||
This function runs the hook `focus-in-hook'."
|
||||
(interactive "e")
|
||||
(run-hooks 'focus-in-hook))
|
||||
|
||||
(defun handle-focus-out (_event)
|
||||
"Handle a focus-out event.
|
||||
Focus-out events are usually bound to this function.
|
||||
Focus-out events occur when no frame has focus.
|
||||
This function runs the hook `focus-out-hook'."
|
||||
(interactive "e")
|
||||
(run-hooks 'focus-out-hook))
|
||||
|
||||
;;;; Arrangement of frames at startup
|
||||
|
||||
|
@ -193,6 +210,8 @@ appended when the minibuffer frame is created."
|
|||
|
||||
(declare-function tool-bar-mode "tool-bar" (&optional arg))
|
||||
|
||||
(defalias 'tool-bar-lines-needed 'tool-bar-height)
|
||||
|
||||
;; startup.el calls this function after loading the user's init
|
||||
;; file. Now default-frame-alist and initial-frame-alist contain
|
||||
;; information to which we must react; do what needs to be done.
|
||||
|
@ -1727,12 +1746,11 @@ command starts, by installing a pre-command hook."
|
|||
"Timer function of timer `blink-cursor-timer'."
|
||||
(internal-show-cursor nil (not (internal-show-cursor-p)))
|
||||
;; Each blink is two calls to this function.
|
||||
(when (memq window-system '(x ns w32))
|
||||
(setq blink-cursor-blinks-done (1+ blink-cursor-blinks-done))
|
||||
(when (and (> blink-cursor-blinks 0)
|
||||
(<= (* 2 blink-cursor-blinks) blink-cursor-blinks-done))
|
||||
(blink-cursor-suspend)
|
||||
(add-hook 'post-command-hook 'blink-cursor-check))))
|
||||
(setq blink-cursor-blinks-done (1+ blink-cursor-blinks-done))
|
||||
(when (and (> blink-cursor-blinks 0)
|
||||
(<= (* 2 blink-cursor-blinks) blink-cursor-blinks-done))
|
||||
(blink-cursor-suspend)
|
||||
(add-hook 'post-command-hook 'blink-cursor-check)))
|
||||
|
||||
|
||||
(defun blink-cursor-end ()
|
||||
|
@ -1747,15 +1765,14 @@ itself as a pre-command hook."
|
|||
(setq blink-cursor-timer nil)))
|
||||
|
||||
(defun blink-cursor-suspend ()
|
||||
"Suspend cursor blinking on NS, X and W32.
|
||||
"Suspend cursor blinking.
|
||||
This is called when no frame has focus and timers can be suspended.
|
||||
Timers are restarted by `blink-cursor-check', which is called when a
|
||||
frame receives focus."
|
||||
(when (memq window-system '(x ns w32))
|
||||
(blink-cursor-end)
|
||||
(when blink-cursor-idle-timer
|
||||
(cancel-timer blink-cursor-idle-timer)
|
||||
(setq blink-cursor-idle-timer nil))))
|
||||
(blink-cursor-end)
|
||||
(when blink-cursor-idle-timer
|
||||
(cancel-timer blink-cursor-idle-timer)
|
||||
(setq blink-cursor-idle-timer nil)))
|
||||
|
||||
(defun blink-cursor-check ()
|
||||
"Check if cursor blinking shall be restarted.
|
||||
|
@ -1789,13 +1806,15 @@ terminals, cursor blinking is controlled by the terminal."
|
|||
(if blink-cursor-idle-timer (cancel-timer blink-cursor-idle-timer))
|
||||
(setq blink-cursor-idle-timer nil)
|
||||
(blink-cursor-end)
|
||||
(remove-hook 'focus-in-hook #'blink-cursor-check)
|
||||
(remove-hook 'focus-out-hook #'blink-cursor-suspend)
|
||||
(when blink-cursor-mode
|
||||
;; Hide the cursor.
|
||||
;;(internal-show-cursor nil nil)
|
||||
(add-hook 'focus-in-hook #'blink-cursor-check)
|
||||
(add-hook 'focus-out-hook #'blink-cursor-suspend)
|
||||
(setq blink-cursor-idle-timer
|
||||
(run-with-idle-timer blink-cursor-delay
|
||||
blink-cursor-delay
|
||||
'blink-cursor-start))))
|
||||
#'blink-cursor-start))))
|
||||
|
||||
|
||||
;; Frame maximization/fullscreen
|
||||
|
|
|
@ -1,3 +1,55 @@
|
|||
2013-12-03 Vitalie Spinu <spinuvit@gmail.com>
|
||||
|
||||
* message.el (message-send-mail-with-sendmail):
|
||||
Don't kill error buffer if sending fails.
|
||||
|
||||
2013-11-28 Jan Tatarik <jan.tatarik@gmail.com>
|
||||
|
||||
* gnus-icalendar.el (gnus-icalendar-event-from-ical)
|
||||
(gnus-icalendar-event->org-entry)
|
||||
(gnus-icalendar--update-org-event)
|
||||
(gnus-icalendar-event->gnus-calendar): Distinguish between
|
||||
required/optional/non-participant attendee status. Fix bug causing
|
||||
the first required event participant to be omitted.
|
||||
|
||||
2013-11-27 Katsumi Yamaoka <yamaoka@jpl.org>
|
||||
|
||||
* gnus-art.el (article-de-quoted-unreadable)
|
||||
(article-de-base64-unreadable, gnus-mime-copy-part)
|
||||
* gnus-html.el (gnus-article-html)
|
||||
* mm-view.el (mm-inline-text-html-render-with-w3)
|
||||
(mm-inline-text-html-render-with-w3m-standalone)
|
||||
* rfc2231.el (rfc2231-decode-encoded-string):
|
||||
Allow overriding charset by mm-charset-override-alist.
|
||||
|
||||
* gnus-art.el (gnus-article-browse-html-parts):
|
||||
Replace LWSPs with ` 's in header.
|
||||
|
||||
Work for broken Chinese articles.
|
||||
|
||||
* gnus-art.el (gnus-article-browse-html-save-cid-content):
|
||||
Exclude broken handles that gnus-summary-enter-digest-group may create.
|
||||
(gnus-article-browse-html-parts):
|
||||
Allow overriding charset by mm-charset-override-alist.
|
||||
|
||||
2013-11-21 Jan Tatarik <jan.tatarik@gmail.com>
|
||||
|
||||
* gnus-icalendar.el (gnus-icalendar-additional-identities): New.
|
||||
(gnus-icalendar-identities): Support additional-identities.
|
||||
|
||||
* gnus-icalendar.el (gnus-icalendar-event:org-timestamp):
|
||||
Fix org-timestamp for events ending at midnight.
|
||||
|
||||
2013-11-21 Ivan Shmakov <ivan@siamics.net> (tiny change)
|
||||
|
||||
* nndoc.el (nndoc-type-alist, nndoc-debbugs-db-type-p):
|
||||
Support debbugs .log files.
|
||||
|
||||
2013-11-20 Dave Goldberg <david.goldberg6@verizon.net>
|
||||
|
||||
* message.el (message-beginning-of-line):
|
||||
Use beginning-of-visual-line when visual-line-mode is turned on.
|
||||
|
||||
2013-11-15 Jan Tatarik <jan.tatarik@gmail.com>
|
||||
|
||||
* gnus-icalendar.el (gnus-icalendar-event->gnus-calendar)
|
||||
|
|
|
@ -2665,7 +2665,7 @@ If READ-CHARSET, ask for a coding system."
|
|||
(string-match "quoted-printable" type))))
|
||||
(article-goto-body)
|
||||
(quoted-printable-decode-region
|
||||
(point) (point-max) (mm-charset-to-coding-system charset))))))
|
||||
(point) (point-max) (mm-charset-to-coding-system charset nil t))))))
|
||||
|
||||
(defun article-de-base64-unreadable (&optional force read-charset)
|
||||
"Translate a base64 article.
|
||||
|
@ -2696,7 +2696,8 @@ If READ-CHARSET, ask for a coding system."
|
|||
(narrow-to-region (point) (point-max))
|
||||
(base64-decode-region (point-min) (point-max))
|
||||
(mm-decode-coding-region
|
||||
(point-min) (point-max) (mm-charset-to-coding-system charset)))))))
|
||||
(point-min) (point-max)
|
||||
(mm-charset-to-coding-system charset nil t)))))))
|
||||
|
||||
(eval-when-compile
|
||||
(require 'rfc1843))
|
||||
|
@ -2794,6 +2795,9 @@ Return file name."
|
|||
(dolist (handle handles)
|
||||
(cond
|
||||
((not (listp handle)))
|
||||
;; Exclude broken handles that `gnus-summary-enter-digest-group'
|
||||
;; may create.
|
||||
((not (or (bufferp (car handle)) (stringp (car handle)))))
|
||||
((equal (mm-handle-media-supertype handle) "multipart")
|
||||
(when (setq file (gnus-article-browse-html-save-cid-content
|
||||
cid handle directory))
|
||||
|
@ -2801,11 +2805,12 @@ Return file name."
|
|||
((equal (concat "<" cid ">") (mm-handle-id handle))
|
||||
(setq file
|
||||
(expand-file-name
|
||||
(or (mm-handle-filename handle)
|
||||
(concat
|
||||
(make-temp-name "cid")
|
||||
(car (rassoc (car (mm-handle-type handle)) mailcap-mime-extensions))))
|
||||
directory))
|
||||
(or (mm-handle-filename handle)
|
||||
(concat
|
||||
(make-temp-name "cid")
|
||||
(car (rassoc (car (mm-handle-type handle))
|
||||
mailcap-mime-extensions))))
|
||||
directory))
|
||||
(mm-save-part-to-file handle file)
|
||||
(throw 'found file))))))))
|
||||
|
||||
|
@ -2891,6 +2896,13 @@ message header will be added to the bodies of the \"text/html\" parts."
|
|||
((match-beginning 3) "&")
|
||||
(t "<br>\n"))))
|
||||
(goto-char (point-min))
|
||||
(while (re-search-forward "^[\t ]+" nil t)
|
||||
(dotimes (i (prog1
|
||||
(current-column)
|
||||
(delete-region (match-beginning 0)
|
||||
(match-end 0))))
|
||||
(insert " ")))
|
||||
(goto-char (point-min))
|
||||
(insert "<div align=\"left\">\n")
|
||||
(goto-char (point-max))
|
||||
(insert "</div>\n<hr>\n")
|
||||
|
@ -2908,7 +2920,7 @@ message header will be added to the bodies of the \"text/html\" parts."
|
|||
(cond ((= (length hcharset) 1)
|
||||
(setq hcharset (car hcharset)
|
||||
coding (mm-charset-to-coding-system
|
||||
hcharset)))
|
||||
hcharset nil t)))
|
||||
((> (length hcharset) 1)
|
||||
(setq hcharset 'utf-8
|
||||
coding hcharset)))
|
||||
|
@ -2916,7 +2928,8 @@ message header will be added to the bodies of the \"text/html\" parts."
|
|||
(if charset
|
||||
(progn
|
||||
(setq body
|
||||
(mm-charset-to-coding-system charset))
|
||||
(mm-charset-to-coding-system charset
|
||||
nil t))
|
||||
(if (eq coding body)
|
||||
(setq eheader (mm-encode-coding-string
|
||||
(buffer-string) coding)
|
||||
|
@ -5235,7 +5248,8 @@ are decompressed."
|
|||
(switch-to-buffer (generate-new-buffer filename))
|
||||
(if (or coding-system
|
||||
(and charset
|
||||
(setq coding-system (mm-charset-to-coding-system charset))
|
||||
(setq coding-system (mm-charset-to-coding-system
|
||||
charset nil t))
|
||||
(not (eq coding-system 'ascii))))
|
||||
(progn
|
||||
(mm-enable-multibyte)
|
||||
|
|
|
@ -143,7 +143,8 @@ CHARS is a regexp-like character alternative (e.g., \"[)$]\")."
|
|||
(charset (mail-content-type-get (mm-handle-type handle)
|
||||
'charset)))
|
||||
(when (and charset
|
||||
(setq charset (mm-charset-to-coding-system charset))
|
||||
(setq charset (mm-charset-to-coding-system
|
||||
charset nil t))
|
||||
(not (eq charset 'ascii)))
|
||||
(insert (prog1
|
||||
(mm-decode-coding-string (buffer-string) charset)
|
||||
|
|
|
@ -92,10 +92,10 @@
|
|||
:accessor gnus-icalendar-event:rsvp
|
||||
:initform nil
|
||||
:type (or null boolean))
|
||||
(participation-required :initarg :participation-required
|
||||
:accessor gnus-icalendar-event:participation-required
|
||||
:initform t
|
||||
:type (or null boolean))
|
||||
(participation-type :initarg :participation-type
|
||||
:accessor gnus-icalendar-event:participation-type
|
||||
:initform 'non-participant
|
||||
:type (or null t))
|
||||
(req-participants :initarg :req-participants
|
||||
:accessor gnus-icalendar-event:req-participants
|
||||
:initform nil
|
||||
|
@ -196,15 +196,18 @@
|
|||
(attendee (when attendee-name-or-email
|
||||
(gnus-icalendar-event--find-attendee ical attendee-name-or-email)))
|
||||
(attendee-names (gnus-icalendar-event--get-attendee-names ical))
|
||||
(role (plist-get (cadr attendee) 'ROLE))
|
||||
(participation-type (pcase role
|
||||
("REQ-PARTICIPANT" 'required)
|
||||
("OPT-PARTICIPANT" 'optional)
|
||||
(_ 'non-participant)))
|
||||
(args (list :method method
|
||||
:organizer organizer
|
||||
:start-time (gnus-icalendar-event--decode-datefield event 'DTSTART)
|
||||
:end-time (gnus-icalendar-event--decode-datefield event 'DTEND)
|
||||
:rsvp (string= (plist-get (cadr attendee) 'RSVP)
|
||||
"TRUE")
|
||||
:participation-required (string= (plist-get (cadr attendee) 'ROLE)
|
||||
"REQ-PARTICIPANT")
|
||||
:req-participants (cdar attendee-names)
|
||||
:rsvp (string= (plist-get (cadr attendee) 'RSVP) "TRUE")
|
||||
:participation-type participation-type
|
||||
:req-participants (car attendee-names)
|
||||
:opt-participants (cadr attendee-names)))
|
||||
(event-class (cond
|
||||
((string= method "REQUEST") 'gnus-icalendar-event-request)
|
||||
|
@ -387,14 +390,46 @@ Return nil for non-recurring EVENT."
|
|||
(end (gnus-icalendar-event:end-time event))
|
||||
(start-date (format-time-string "%Y-%m-%d %a" start))
|
||||
(start-time (format-time-string "%H:%M" start))
|
||||
(start-at-midnight (string= start-time "00:00"))
|
||||
(end-date (format-time-string "%Y-%m-%d %a" end))
|
||||
(end-time (format-time-string "%H:%M" end))
|
||||
(end-at-midnight (string= end-time "00:00"))
|
||||
(start-end-date-diff (/ (float-time (time-subtract
|
||||
(date-to-time end-date)
|
||||
(date-to-time start-date)))
|
||||
86400))
|
||||
(org-repeat (gnus-icalendar-event:org-repeat event))
|
||||
(repeat (if org-repeat (concat " " org-repeat) "")))
|
||||
(repeat (if org-repeat (concat " " org-repeat) ""))
|
||||
(time-1-day '(0 86400)))
|
||||
|
||||
(if (equal start-date end-date)
|
||||
(format "<%s %s-%s%s>" start-date start-time end-time repeat)
|
||||
(format "<%s %s>--<%s %s>" start-date start-time end-date end-time))))
|
||||
;; NOTE: special care is needed with appointments ending at midnight
|
||||
;; (typically all-day events): the end time has to be changed to 23:59 to
|
||||
;; prevent org agenda showing the event on one additional day
|
||||
(cond
|
||||
;; start/end midnight
|
||||
;; A 0:0 - A+1 0:0 -> A
|
||||
;; A 0:0 - A+n 0:0 -> A - A+n-1
|
||||
((and start-at-midnight end-at-midnight) (if (> start-end-date-diff 1)
|
||||
(let ((end-ts (format-time-string "%Y-%m-%d %a" (time-subtract end time-1-day))))
|
||||
(format "<%s>--<%s>" start-date end-ts))
|
||||
(format "<%s%s>" start-date repeat)))
|
||||
;; end midnight
|
||||
;; A .:. - A+1 0:0 -> A .:.-23:59
|
||||
;; A .:. - A+n 0:0 -> A .:. - A_n-1
|
||||
(end-at-midnight (if (= start-end-date-diff 1)
|
||||
(format "<%s %s-23:59%s>" start-date start-time repeat)
|
||||
(let ((end-ts (format-time-string "%Y-%m-%d %a" (time-subtract end time-1-day))))
|
||||
(format "<%s %s>--<%s>" start-date start-time end-ts))))
|
||||
;; start midnight
|
||||
;; A 0:0 - A .:. -> A 0:0-.:. (default 1)
|
||||
;; A 0:0 - A+n .:. -> A - A+n .:.
|
||||
((and start-at-midnight
|
||||
(plusp start-end-date-diff)) (format "<%s>--<%s %s>" start-date end-date end-time))
|
||||
;; default
|
||||
;; A .:. - A .:. -> A .:.-.:.
|
||||
;; A .:. - B .:.
|
||||
((zerop start-end-date-diff) (format "<%s %s-%s%s>" start-date start-time end-time repeat))
|
||||
(t (format "<%s %s>--<%s %s>" start-date start-time end-date end-time)))))
|
||||
|
||||
(defun gnus-icalendar--format-summary-line (summary &optional location)
|
||||
(if location
|
||||
|
@ -419,7 +454,7 @@ Return nil for non-recurring EVENT."
|
|||
("DT" . ,(gnus-icalendar-event:org-timestamp event))
|
||||
("ORGANIZER" . ,(gnus-icalendar-event:organizer event))
|
||||
("LOCATION" . ,(gnus-icalendar-event:location event))
|
||||
("PARTICIPATION_REQUIRED" . ,(when (gnus-icalendar-event:participation-required event) "t"))
|
||||
("PARTICIPATION_TYPE" . ,(symbol-name (gnus-icalendar-event:participation-type event)))
|
||||
("REQ_PARTICIPANTS" . ,(gnus-icalendar--format-participant-list (gnus-icalendar-event:req-participants event)))
|
||||
("OPT_PARTICIPANTS" . ,(gnus-icalendar--format-participant-list (gnus-icalendar-event:opt-participants event)))
|
||||
("RRULE" . ,(gnus-icalendar-event:recur event))
|
||||
|
@ -481,7 +516,7 @@ is searched."
|
|||
(when file
|
||||
(with-current-buffer (find-file-noselect file)
|
||||
(with-slots (uid summary description organizer location recur
|
||||
participation-required req-participants opt-participants) event
|
||||
participation-type req-participants opt-participants) event
|
||||
(let ((event-pos (org-find-entry-with-id uid)))
|
||||
(when event-pos
|
||||
(goto-char event-pos)
|
||||
|
@ -523,7 +558,7 @@ is searched."
|
|||
(org-entry-put event-pos "DT" (gnus-icalendar-event:org-timestamp event))
|
||||
(org-entry-put event-pos "ORGANIZER" organizer)
|
||||
(org-entry-put event-pos "LOCATION" location)
|
||||
(org-entry-put event-pos "PARTICIPATION_REQUIRED" (when participation-required "t"))
|
||||
(org-entry-put event-pos "PARTICIPATION_TYPE" (symbol-name participation-type))
|
||||
(org-entry-put event-pos "REQ_PARTICIPANTS" (gnus-icalendar--format-participant-list req-participants))
|
||||
(org-entry-put event-pos "OPT_PARTICIPANTS" (gnus-icalendar--format-participant-list opt-participants))
|
||||
(org-entry-put event-pos "RRULE" recur)
|
||||
|
@ -617,6 +652,22 @@ is searched."
|
|||
:type '(string)
|
||||
:group 'gnus-icalendar)
|
||||
|
||||
(defcustom gnus-icalendar-additional-identities nil
|
||||
"We need to know your identity to make replies to calendar requests work.
|
||||
|
||||
Gnus will only offer you the Accept/Tentative/Decline buttons for
|
||||
calendar events if any of your identities matches at least one
|
||||
RSVP participant.
|
||||
|
||||
Your identity is guessed automatically from the variables `user-full-name',
|
||||
`user-mail-address', and `gnus-ignored-from-addresses'.
|
||||
|
||||
If you need even more aliases you can define them here. It really
|
||||
only makes sense to define names or email addresses."
|
||||
|
||||
:type '(repeat string)
|
||||
:group 'gnus-icalendar)
|
||||
|
||||
(make-variable-buffer-local
|
||||
(defvar gnus-icalendar-reply-status nil))
|
||||
|
||||
|
@ -630,8 +681,9 @@ is searched."
|
|||
(apply #'append
|
||||
(mapcar (lambda (x) (if (listp x) x (list x)))
|
||||
(list user-full-name (regexp-quote user-mail-address)
|
||||
; NOTE: this one can be a list
|
||||
gnus-ignored-from-addresses))))
|
||||
; NOTE: these can be lists
|
||||
gnus-ignored-from-addresses ; already regexp-quoted
|
||||
(mapcar #'regexp-quote gnus-icalendar-additional-identities)))))
|
||||
|
||||
;; TODO: make the template customizable
|
||||
(defmethod gnus-icalendar-event->gnus-calendar ((event gnus-icalendar-event) &optional reply-status)
|
||||
|
@ -642,12 +694,14 @@ is searched."
|
|||
(cadr x))))
|
||||
|
||||
(with-slots (organizer summary description location recur uid
|
||||
method rsvp participation-required) event
|
||||
method rsvp participation-type) event
|
||||
(let ((headers `(("Summary" ,summary)
|
||||
("Location" ,(or location ""))
|
||||
("Time" ,(gnus-icalendar-event:org-timestamp event))
|
||||
("Organizer" ,organizer)
|
||||
("Attendance" ,(if participation-required "Required" "Optional"))
|
||||
("Attendance" ,(if (eq participation-type 'non-participant)
|
||||
"You are not listed as an attendee"
|
||||
(capitalize (symbol-name participation-type))))
|
||||
("Method" ,method))))
|
||||
|
||||
(when (and (not (gnus-icalendar-event-reply-p event)) rsvp)
|
||||
|
|
|
@ -4739,7 +4739,9 @@ that instead."
|
|||
(list resend-to-addresses)
|
||||
'("-t"))))))
|
||||
(unless (or (null cpr) (and (numberp cpr) (zerop cpr)))
|
||||
(if errbuf (pop-to-buffer errbuf))
|
||||
(when errbuf
|
||||
(pop-to-buffer errbuf)
|
||||
(setq errbuf nil))
|
||||
(error "Sending...failed with exit value %d" cpr)))
|
||||
(when message-interactive
|
||||
(with-current-buffer errbuf
|
||||
|
@ -6271,6 +6273,9 @@ they are."
|
|||
:link '(custom-manual "(message)Movement")
|
||||
:type 'boolean)
|
||||
|
||||
(defvar visual-line-mode)
|
||||
(declare-function beginning-of-visual-line "simple" (&optional n))
|
||||
|
||||
(defun message-beginning-of-line (&optional n)
|
||||
"Move point to beginning of header value or to beginning of line.
|
||||
The prefix argument N is passed directly to `beginning-of-line'.
|
||||
|
@ -6297,7 +6302,9 @@ between beginning of field and beginning of line."
|
|||
(goto-char
|
||||
(if (and eoh (or (< eoh here) (= bol here)))
|
||||
eoh bol)))
|
||||
(beginning-of-line n)))
|
||||
(if (and (boundp 'visual-line-mode) visual-line-mode)
|
||||
(beginning-of-visual-line n)
|
||||
(beginning-of-line n))))
|
||||
|
||||
(defun message-buffer-name (type &optional to group)
|
||||
"Return a new (unique) buffer name based on TYPE and TO."
|
||||
|
|
|
@ -175,7 +175,7 @@
|
|||
(match-end 2))))
|
||||
(if (fboundp 'w3-coding-system-for-mime-charset)
|
||||
(w3-coding-system-for-mime-charset bsubstr)
|
||||
(mm-charset-to-coding-system bsubstr))))
|
||||
(mm-charset-to-coding-system bsubstr nil t))))
|
||||
(delete-region (point-min) (point-max))
|
||||
(insert (mm-decode-string text charset))))
|
||||
(save-window-excursion
|
||||
|
@ -343,9 +343,10 @@
|
|||
'charset)
|
||||
(symbol-name mail-parse-charset)))
|
||||
cs)
|
||||
(unless (and charset
|
||||
(setq cs (mm-charset-to-coding-system charset))
|
||||
(not (eq cs 'ascii)))
|
||||
(if (and charset
|
||||
(setq cs (mm-charset-to-coding-system charset nil t))
|
||||
(not (eq cs 'ascii)))
|
||||
(setq charset (format "%s" (mm-coding-system-to-mime-charset cs)))
|
||||
;; The default.
|
||||
(setq charset "iso-8859-1"
|
||||
cs 'iso-8859-1))
|
||||
|
|
|
@ -56,6 +56,10 @@ from the document.")
|
|||
`((mmdf
|
||||
(article-begin . "^\^A\^A\^A\^A\n")
|
||||
(body-end . "^\^A\^A\^A\^A\n"))
|
||||
(debbugs-db
|
||||
(file-begin . "^\005")
|
||||
(article-begin . "^[\005\007]\n")
|
||||
(body-end . "^\003"))
|
||||
(mime-digest
|
||||
(article-begin . "")
|
||||
(head-begin . "^ ?\n")
|
||||
|
@ -460,6 +464,10 @@ from the document.")
|
|||
(when (looking-at "\^A\^A\^A\^A$")
|
||||
t))
|
||||
|
||||
(defun nndoc-debbugs-db-type-p ()
|
||||
(when (looking-at "\006$")
|
||||
t))
|
||||
|
||||
(defun nndoc-news-type-p ()
|
||||
(when (looking-at "^Path:.*\n")
|
||||
t))
|
||||
|
|
|
@ -215,7 +215,8 @@ These look like:
|
|||
\"''This%20is%20%2A%2A%2Afun%2A%2A%2A\", or
|
||||
\"This is ***fun***\"."
|
||||
(string-match "\\`\\(?:\\([^']+\\)?'\\([^']+\\)?'\\)?\\(.+\\)" string)
|
||||
(let ((coding-system (mm-charset-to-coding-system (match-string 1 string)))
|
||||
(let ((coding-system (mm-charset-to-coding-system
|
||||
(match-string 1 string) nil t))
|
||||
;;(language (match-string 2 string))
|
||||
(value (match-string 3 string)))
|
||||
(mm-with-unibyte-buffer
|
||||
|
|
134
lisp/help.el
134
lisp/help.el
|
@ -493,9 +493,8 @@ The optional argument MENUS, if non-nil, says to mention menu bindings.
|
|||
The optional argument PREFIX, if non-nil, should be a key sequence;
|
||||
then we display only bindings that start with that prefix."
|
||||
(let ((buf (current-buffer)))
|
||||
(with-help-window "*Help*"
|
||||
(with-current-buffer standard-output
|
||||
(describe-buffer-bindings buf prefix menus)))))
|
||||
(with-help-window (help-buffer)
|
||||
(describe-buffer-bindings buf prefix menus))))
|
||||
|
||||
(defun where-is (definition &optional insert)
|
||||
"Print message listing key sequences that invoke the command DEFINITION.
|
||||
|
@ -983,6 +982,23 @@ function is called, the window to be resized is selected."
|
|||
:group 'help
|
||||
:version "24.3")
|
||||
|
||||
(defcustom temp-buffer-max-width
|
||||
(lambda (buffer)
|
||||
(if (eq (selected-window) (frame-root-window))
|
||||
(/ (x-display-pixel-width) (frame-char-width) 2)
|
||||
(/ (- (frame-width) 2) 2)))
|
||||
"Maximum width of a window displaying a temporary buffer.
|
||||
This is effective only when Temp Buffer Resize mode is enabled.
|
||||
The value is the maximum width (in columns) which
|
||||
`resize-temp-buffer-window' will give to a window displaying a
|
||||
temporary buffer. It can also be a function to be called to
|
||||
choose the width for such a buffer. It gets one argument, the
|
||||
buffer, and should return a positive integer. At the time the
|
||||
function is called, the window to be resized is selected."
|
||||
:type '(choice integer function)
|
||||
:group 'help
|
||||
:version "24.4")
|
||||
|
||||
(define-minor-mode temp-buffer-resize-mode
|
||||
"Toggle auto-resizing temporary buffer windows (Temp Buffer Resize Mode).
|
||||
With a prefix argument ARG, enable Temp Buffer Resize mode if ARG
|
||||
|
@ -1010,33 +1026,40 @@ and some others."
|
|||
|
||||
(defun resize-temp-buffer-window (&optional window)
|
||||
"Resize WINDOW to fit its contents.
|
||||
WINDOW can be any live window and defaults to the selected one.
|
||||
WINDOW must be a live window and defaults to the selected one.
|
||||
Do not resize if WINDOW was not created by `display-buffer'.
|
||||
|
||||
Do not make WINDOW higher than `temp-buffer-max-height' nor
|
||||
smaller than `window-min-height'. Do nothing if WINDOW is not
|
||||
vertically combined, some of its contents are scrolled out of
|
||||
view, or WINDOW was not created by `display-buffer'."
|
||||
If WINDOW is part of a vertical combination, restrain its new
|
||||
size by `temp-buffer-max-height' and do not resize if its minimum
|
||||
accessible position is scrolled out of view. If WINDOW is part
|
||||
of a horizontal combination, restrain its new size by
|
||||
`temp-buffer-max-width'. In both cases, the value of the option
|
||||
`fit-window-to-buffer-horizontally' can inhibit resizing.
|
||||
|
||||
If WINDOW is the root window of its frame, resize the frame
|
||||
provided `fit-frame-to-buffer' is non-nil."
|
||||
(setq window (window-normalize-window window t))
|
||||
(let ((height (if (functionp temp-buffer-max-height)
|
||||
(with-selected-window window
|
||||
(funcall temp-buffer-max-height (window-buffer)))
|
||||
temp-buffer-max-height))
|
||||
(width (if (functionp temp-buffer-max-width)
|
||||
(with-selected-window window
|
||||
(funcall temp-buffer-max-width (window-buffer)))
|
||||
temp-buffer-max-width))
|
||||
(quit-cadr (cadr (window-parameter window 'quit-restore))))
|
||||
(cond
|
||||
;; Resize WINDOW iff it was split off by `display-buffer'.
|
||||
((and (eq quit-cadr 'window)
|
||||
(pos-visible-in-window-p (point-min) window)
|
||||
(window-combined-p window))
|
||||
(fit-window-to-buffer window height))
|
||||
;; Resize FRAME iff it was created by `display-buffer'.
|
||||
((and fit-frame-to-buffer
|
||||
(eq quit-cadr 'frame)
|
||||
(eq window (frame-root-window window)))
|
||||
(let ((frame (window-frame window)))
|
||||
(fit-frame-to-buffer
|
||||
frame (+ (frame-height frame)
|
||||
(- (window-total-size window))
|
||||
height)))))))
|
||||
;; Resize WINDOW iff it was made by `display-buffer'.
|
||||
(when (or (and (eq quit-cadr 'window)
|
||||
(or (and (window-combined-p window)
|
||||
(not (eq fit-window-to-buffer-horizontally
|
||||
'only))
|
||||
(pos-visible-in-window-p (point-min) window))
|
||||
(and (window-combined-p window t)
|
||||
fit-window-to-buffer-horizontally)))
|
||||
(and (eq quit-cadr 'frame)
|
||||
fit-frame-to-buffer
|
||||
(eq window (frame-root-window window))))
|
||||
(fit-window-to-buffer window height nil width))))
|
||||
|
||||
;;; Help windows.
|
||||
(defcustom help-window-select 'other
|
||||
|
@ -1089,28 +1112,29 @@ window."
|
|||
(message "%s"
|
||||
(substitute-command-keys (concat quit-part scroll-part)))))
|
||||
|
||||
(defun help-window-setup (help-window)
|
||||
"Set up help window for `with-help-window'.
|
||||
HELP-WINDOW is the window used for displaying the help buffer."
|
||||
(let* ((help-buffer (when (window-live-p help-window)
|
||||
(window-buffer help-window)))
|
||||
(help-setup (when (window-live-p help-window)
|
||||
(car (window-parameter help-window 'quit-restore)))))
|
||||
(defun help-window-setup (window &optional value)
|
||||
"Set up help window WINDOW for `with-help-window'.
|
||||
WINDOW is the window used for displaying the help buffer.
|
||||
Return VALUE."
|
||||
(let* ((help-buffer (when (window-live-p window)
|
||||
(window-buffer window)))
|
||||
(help-setup (when (window-live-p window)
|
||||
(car (window-parameter window 'quit-restore)))))
|
||||
(when help-buffer
|
||||
;; Handle `help-window-point-marker'.
|
||||
(when (eq (marker-buffer help-window-point-marker) help-buffer)
|
||||
(set-window-point help-window help-window-point-marker)
|
||||
(set-window-point window help-window-point-marker)
|
||||
;; Reset `help-window-point-marker'.
|
||||
(set-marker help-window-point-marker nil))
|
||||
|
||||
(cond
|
||||
((or (eq help-window (selected-window))
|
||||
((or (eq window (selected-window))
|
||||
(and (or (eq help-window-select t)
|
||||
(eq help-setup 'frame)
|
||||
(and (eq help-window-select 'other)
|
||||
(eq (window-frame help-window) (selected-frame))
|
||||
(eq (window-frame window) (selected-frame))
|
||||
(> (length (window-list nil 'no-mini)) 2)))
|
||||
(select-window help-window)))
|
||||
(select-window window)))
|
||||
;; The help window is or gets selected ...
|
||||
(help-window-display-message
|
||||
(cond
|
||||
|
@ -1118,12 +1142,12 @@ HELP-WINDOW is the window used for displaying the help buffer."
|
|||
;; ... and is new, ...
|
||||
"Type \"q\" to delete help window")
|
||||
((eq help-setup 'frame)
|
||||
"Type \"q\" to delete help frame")
|
||||
"Type \"q\" to quit the help frame")
|
||||
((eq help-setup 'other)
|
||||
;; ... or displayed some other buffer before.
|
||||
"Type \"q\" to restore previous buffer"))
|
||||
help-window t))
|
||||
((and (eq (window-frame help-window) (selected-frame))
|
||||
window t))
|
||||
((and (eq (window-frame window) (selected-frame))
|
||||
(= (length (window-list nil 'no-mini)) 2))
|
||||
;; There are two windows on the help window's frame and the
|
||||
;; other one is the selected one.
|
||||
|
@ -1133,7 +1157,7 @@ HELP-WINDOW is the window used for displaying the help buffer."
|
|||
"Type \\[delete-other-windows] to delete the help window")
|
||||
((eq help-setup 'other)
|
||||
"Type \"q\" in help window to restore its previous buffer"))
|
||||
help-window 'other))
|
||||
window 'other))
|
||||
(t
|
||||
;; The help window is not selected ...
|
||||
(help-window-display-message
|
||||
|
@ -1144,40 +1168,42 @@ HELP-WINDOW is the window used for displaying the help buffer."
|
|||
((eq help-setup 'other)
|
||||
;; ... or displayed some other buffer before.
|
||||
"Type \"q\" in help window to restore previous buffer"))
|
||||
help-window))))))
|
||||
window))))
|
||||
;; Return VALUE.
|
||||
value))
|
||||
|
||||
;; `with-help-window' is a wrapper for `with-output-to-temp-buffer'
|
||||
;; `with-help-window' is a wrapper for `with-temp-buffer-window'
|
||||
;; providing the following additional twists:
|
||||
|
||||
;; (1) Issue more accurate messages telling how to scroll and quit the
|
||||
;; help window.
|
||||
;; (1) It puts the buffer in `help-mode' (via `help-mode-setup') and
|
||||
;; adds cross references (via `help-mode-finish').
|
||||
|
||||
;; (2) An option (customizable via `help-window-select') to select the
|
||||
;; (2) It issues a message telling how to scroll and quit the help
|
||||
;; window (via `help-window-setup').
|
||||
|
||||
;; (3) An option (customizable via `help-window-select') to select the
|
||||
;; help window automatically.
|
||||
|
||||
;; (3) A marker (`help-window-point-marker') to move point in the help
|
||||
;; (4) A marker (`help-window-point-marker') to move point in the help
|
||||
;; window to an arbitrary buffer position.
|
||||
|
||||
;; Note: It's usually always wrong to use `help-print-return-message' in
|
||||
;; the body of `with-help-window'.
|
||||
(defmacro with-help-window (buffer-name &rest body)
|
||||
"Display buffer with name BUFFER-NAME in a help window evaluating BODY.
|
||||
Select help window if the actual value of the user option
|
||||
Select help window if the current value of the user option
|
||||
`help-window-select' says so. Return last value in BODY."
|
||||
(declare (indent 1) (debug t))
|
||||
`(progn
|
||||
;; Make `help-window-point-marker' point nowhere. The only place
|
||||
;; where this should be set to a buffer position is within BODY.
|
||||
(set-marker help-window-point-marker nil)
|
||||
(let* (help-window
|
||||
(temp-buffer-show-hook
|
||||
(cons (lambda () (setq help-window (selected-window)))
|
||||
temp-buffer-show-hook)))
|
||||
;; Return value returned by `with-output-to-temp-buffer'.
|
||||
(prog1
|
||||
(with-output-to-temp-buffer ,buffer-name
|
||||
(progn ,@body))
|
||||
(help-window-setup help-window)))))
|
||||
(let ((temp-buffer-window-setup-hook
|
||||
(cons 'help-mode-setup temp-buffer-window-setup-hook))
|
||||
(temp-buffer-window-show-hook
|
||||
(cons 'help-mode-finish temp-buffer-window-show-hook)))
|
||||
(with-temp-buffer-window
|
||||
,buffer-name nil 'help-window-setup (progn ,@body)))))
|
||||
|
||||
;; Called from C, on encountering `help-char' when reading a char.
|
||||
;; Don't print to *Help*; that would clobber Help history.
|
||||
|
|
|
@ -185,6 +185,13 @@ with name concatenation."
|
|||
:type 'string
|
||||
:group 'imenu)
|
||||
|
||||
(defcustom imenu-generic-skip-comments-and-strings t
|
||||
"When non-nil, ignore text inside comments and strings.
|
||||
Only affects `imenu--generic-function'."
|
||||
:type 'boolean
|
||||
:group 'imenu
|
||||
:version "24.4")
|
||||
|
||||
;;;###autoload
|
||||
(defvar imenu-generic-expression nil
|
||||
"List of definition matchers for creating an Imenu index.
|
||||
|
@ -286,8 +293,10 @@ The function in this variable is called when selecting a normal index-item.")
|
|||
|
||||
|
||||
(defun imenu--subalist-p (item)
|
||||
(and (consp (cdr item)) (listp (cadr item))
|
||||
(not (eq (car (cadr item)) 'lambda))))
|
||||
(and (consp item)
|
||||
(consp (cdr item))
|
||||
(listp (cadr item))
|
||||
(not (functionp (cadr item)))))
|
||||
|
||||
(defmacro imenu-progress-message (_prevpos &optional _relpos _reverse)
|
||||
"Macro to display a progress message.
|
||||
|
@ -454,7 +463,7 @@ Special elements look like (INDEX-NAME POSITION FUNCTION ARGUMENTS...).
|
|||
To \"go to\" a special element means applying FUNCTION
|
||||
to INDEX-NAME, POSITION, and the ARGUMENTS.
|
||||
|
||||
A nested sub-alist element looks like (INDEX-NAME SUB-ALIST).
|
||||
A nested sub-alist element looks like (INDEX-NAME . SUB-ALIST).
|
||||
The function `imenu--subalist-p' tests an element and returns t
|
||||
if it is a sub-alist.
|
||||
|
||||
|
@ -638,9 +647,11 @@ Non-nil arguments are in recursive calls."
|
|||
;; (INDEX-NAME (INDEX-NAME . INDEX-POSITION) ...)
|
||||
;; while a bottom-level element looks like
|
||||
;; (INDEX-NAME . INDEX-POSITION)
|
||||
;; or
|
||||
;; (INDEX-NAME INDEX-POSITION FUNCTION ARGUMENTS...)
|
||||
;; We are only interested in the bottom-level elements, so we need to
|
||||
;; recurse if TAIL is a list.
|
||||
(cond ((listp tail)
|
||||
;; recurse if TAIL is a nested ALIST.
|
||||
(cond ((imenu--subalist-p elt)
|
||||
(if (setq res (imenu--in-alist str tail))
|
||||
(setq alist nil)))
|
||||
((if imenu-name-lookup-function
|
||||
|
@ -796,7 +807,9 @@ depending on PATTERNS."
|
|||
;; starting with its title (or nil).
|
||||
(menu (assoc menu-title index-alist)))
|
||||
;; Insert the item unless it is already present.
|
||||
(unless (member item (cdr menu))
|
||||
(unless (or (member item (cdr menu))
|
||||
(and imenu-generic-skip-comments-and-strings
|
||||
(nth 8 (syntax-ppss))))
|
||||
(setcdr menu
|
||||
(cons item (cdr menu)))))
|
||||
;; Go to the start of the match, to make sure we
|
||||
|
@ -1024,8 +1037,8 @@ for more information."
|
|||
(nth 2 index-item) imenu-default-goto-function))
|
||||
(position (if is-special-item
|
||||
(cadr index-item) (cdr index-item)))
|
||||
(rest (if is-special-item (cddr index-item))))
|
||||
(apply function (car index-item) position rest))
|
||||
(args (if is-special-item (cdr (cddr index-item)))))
|
||||
(apply function (car index-item) position args))
|
||||
(run-hooks 'imenu-after-jump-hook)))
|
||||
|
||||
(provide 'imenu)
|
||||
|
|
17
lisp/international/.gitignore
vendored
17
lisp/international/.gitignore
vendored
|
@ -1 +1,16 @@
|
|||
*.elc
|
||||
# Generated Unicode files.
|
||||
charprop.el
|
||||
uni-bidi.el
|
||||
uni-category.el
|
||||
uni-combining.el
|
||||
uni-comment.el
|
||||
uni-decimal.el
|
||||
uni-decomposition.el
|
||||
uni-digit.el
|
||||
uni-lowercase.el
|
||||
uni-mirrored.el
|
||||
uni-name.el
|
||||
uni-numeric.el
|
||||
uni-old-name.el
|
||||
uni-titlecase.el
|
||||
uni-uppercase.el
|
||||
|
|
|
@ -484,13 +484,16 @@ with L, LRE, or LRO Unicode bidi character type.")
|
|||
|
||||
;; Bidi categories
|
||||
|
||||
(map-char-table (lambda (key val)
|
||||
(cond
|
||||
((memq val '(R AL RLO RLE))
|
||||
(modify-category-entry key ?R))
|
||||
((memq val '(L LRE LRO))
|
||||
(modify-category-entry key ?L))))
|
||||
(unicode-property-table-internal 'bidi-class))
|
||||
;; If bootstrapping without generated uni-*.el files, table not defined.
|
||||
(let ((table (unicode-property-table-internal 'bidi-class)))
|
||||
(when table
|
||||
(map-char-table (lambda (key val)
|
||||
(cond
|
||||
((memq val '(R AL RLO RLE))
|
||||
(modify-category-entry key ?R))
|
||||
((memq val '(L LRE LRO))
|
||||
(modify-category-entry key ?L))))
|
||||
table)))
|
||||
|
||||
;; Latin
|
||||
|
||||
|
@ -1332,15 +1335,15 @@ Setup char-width-table appropriate for non-CJK language environment."
|
|||
|
||||
;;; Setting unicode-category-table.
|
||||
|
||||
(setq unicode-category-table
|
||||
(unicode-property-table-internal 'general-category))
|
||||
(map-char-table #'(lambda (key val)
|
||||
(if (and val
|
||||
(or (and (/= (aref (symbol-name val) 0) ?M)
|
||||
(/= (aref (symbol-name val) 0) ?C))
|
||||
(eq val 'Zs)))
|
||||
(modify-category-entry key ?.)))
|
||||
unicode-category-table)
|
||||
(when (setq unicode-category-table
|
||||
(unicode-property-table-internal 'general-category))
|
||||
(map-char-table #'(lambda (key val)
|
||||
(if (and val
|
||||
(or (and (/= (aref (symbol-name val) 0) ?M)
|
||||
(/= (aref (symbol-name val) 0) ?C))
|
||||
(eq val 'Zs)))
|
||||
(modify-category-entry key ?.)))
|
||||
unicode-category-table))
|
||||
|
||||
(optimize-char-table (standard-category-table))
|
||||
|
||||
|
@ -1426,23 +1429,24 @@ This function updates the char-table `glyphless-char-display'."
|
|||
(glyphless-set-char-table-range glyphless-char-display
|
||||
#x80 #x9F method))
|
||||
((eq target 'format-control)
|
||||
(map-char-table
|
||||
#'(lambda (char category)
|
||||
(if (eq category 'Cf)
|
||||
(let ((this-method method)
|
||||
from to)
|
||||
(if (consp char)
|
||||
(setq from (car char) to (cdr char))
|
||||
(setq from char to char))
|
||||
(while (<= from to)
|
||||
(when (/= from #xAD)
|
||||
(if (eq method 'acronym)
|
||||
(setq this-method
|
||||
(aref char-acronym-table from)))
|
||||
(set-char-table-range glyphless-char-display
|
||||
from this-method))
|
||||
(setq from (1+ from))))))
|
||||
unicode-category-table))
|
||||
(when unicode-category-table
|
||||
(map-char-table
|
||||
#'(lambda (char category)
|
||||
(if (eq category 'Cf)
|
||||
(let ((this-method method)
|
||||
from to)
|
||||
(if (consp char)
|
||||
(setq from (car char) to (cdr char))
|
||||
(setq from char to char))
|
||||
(while (<= from to)
|
||||
(when (/= from #xAD)
|
||||
(if (eq method 'acronym)
|
||||
(setq this-method
|
||||
(aref char-acronym-table from)))
|
||||
(set-char-table-range glyphless-char-display
|
||||
from this-method))
|
||||
(setq from (1+ from))))))
|
||||
unicode-category-table)))
|
||||
((eq target 'no-font)
|
||||
(set-char-table-extra-slot glyphless-char-display 0 method))
|
||||
(t
|
||||
|
|
|
@ -1,88 +0,0 @@
|
|||
;; Automatically generated by unidata-gen.el.
|
||||
;; FILE: uni-name.el
|
||||
(define-char-code-property 'name "uni-name.el"
|
||||
"Unicode character name.
|
||||
Property value is a string or nil.
|
||||
The value nil stands for the default value \"null string\").")
|
||||
;; FILE: uni-category.el
|
||||
(define-char-code-property 'general-category "uni-category.el"
|
||||
"Unicode general category.
|
||||
Property value is one of the following symbols:
|
||||
Lu, Ll, Lt, Lm, Lo, Mn, Mc, Me, Nd, Nl, No, Pc, Pd, Ps, Pe, Pi, Pf, Po,
|
||||
Sm, Sc, Sk, So, Zs, Zl, Zp, Cc, Cf, Cs, Co, Cn")
|
||||
;; FILE: uni-combining.el
|
||||
(define-char-code-property 'canonical-combining-class "uni-combining.el"
|
||||
"Unicode canonical combining class.
|
||||
Property value is an integer.")
|
||||
;; FILE: uni-bidi.el
|
||||
(define-char-code-property 'bidi-class "uni-bidi.el"
|
||||
"Unicode bidi class.
|
||||
Property value is one of the following symbols:
|
||||
L, LRE, LRO, R, AL, RLE, RLO, PDF, EN, ES, ET,
|
||||
AN, CS, NSM, BN, B, S, WS, ON")
|
||||
;; FILE: uni-decomposition.el
|
||||
(define-char-code-property 'decomposition "uni-decomposition.el"
|
||||
"Unicode decomposition mapping.
|
||||
Property value is a list of characters. The first element may be
|
||||
one of these symbols representing compatibility formatting tag:
|
||||
font, noBreak, initial, medial, final, isolated, circle, super,
|
||||
sub, vertical, wide, narrow, small, square, fraction, compat")
|
||||
;; FILE: uni-decimal.el
|
||||
(define-char-code-property 'decimal-digit-value "uni-decimal.el"
|
||||
"Unicode numeric value (decimal digit).
|
||||
Property value is an integer 0..9, or nil.
|
||||
The value nil stands for NaN \"Numeric_Value\".")
|
||||
;; FILE: uni-digit.el
|
||||
(define-char-code-property 'digit-value "uni-digit.el"
|
||||
"Unicode numeric value (digit).
|
||||
Property value is an integer 0..9, or nil.
|
||||
The value nil stands for NaN \"Numeric_Value\".")
|
||||
;; FILE: uni-numeric.el
|
||||
(define-char-code-property 'numeric-value "uni-numeric.el"
|
||||
"Unicode numeric value (numeric).
|
||||
Property value is an integer, a floating point, or nil.
|
||||
The value nil stands for NaN \"Numeric_Value\".")
|
||||
;; FILE: uni-mirrored.el
|
||||
(define-char-code-property 'mirrored "uni-mirrored.el"
|
||||
"Unicode bidi mirrored flag.
|
||||
Property value is a symbol `Y' or `N'. See also the property `mirroring'.")
|
||||
;; FILE: uni-old-name.el
|
||||
(define-char-code-property 'old-name "uni-old-name.el"
|
||||
"Unicode old names as published in Unicode 1.0.
|
||||
Property value is a string or nil.
|
||||
The value nil stands for the default value \"null string\").")
|
||||
;; FILE: uni-comment.el
|
||||
(define-char-code-property 'iso-10646-comment "uni-comment.el"
|
||||
"Unicode ISO 10646 comment.
|
||||
Property value is a string.")
|
||||
;; FILE: uni-uppercase.el
|
||||
(define-char-code-property 'uppercase "uni-uppercase.el"
|
||||
"Unicode simple uppercase mapping.
|
||||
Property value is a character or nil.
|
||||
The value nil means that the actual property value of a character
|
||||
is the character itself.")
|
||||
;; FILE: uni-lowercase.el
|
||||
(define-char-code-property 'lowercase "uni-lowercase.el"
|
||||
"Unicode simple lowercase mapping.
|
||||
Property value is a character or nil.
|
||||
The value nil means that the actual property value of a character
|
||||
is the character itself.")
|
||||
;; FILE: uni-titlecase.el
|
||||
(define-char-code-property 'titlecase "uni-titlecase.el"
|
||||
"Unicode simple titlecase mapping.
|
||||
Property value is a character or nil.
|
||||
The value nil means that the actual property value of a character
|
||||
is the character itself.")
|
||||
;; FILE: uni-mirrored.el
|
||||
(define-char-code-property 'mirroring "uni-mirrored.el"
|
||||
"Unicode bidi-mirroring characters.
|
||||
Property value is a character that has the corresponding mirroring image or nil.
|
||||
The value nil means that the actual property value of a character
|
||||
is the character itself.")
|
||||
;; Local Variables:
|
||||
;; coding: utf-8
|
||||
;; version-control: never
|
||||
;; no-byte-compile: t
|
||||
;; End:
|
||||
|
||||
;; charprop.el ends here
|
|
@ -1,5 +1,7 @@
|
|||
;;; ja-dic-cnv.el --- convert a Japanese dictionary (SKK-JISYO.L) to Emacs Lisp
|
||||
|
||||
;; Copyright (C) 2001-2013 Free Software Foundation, Inc.
|
||||
|
||||
;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
|
||||
;; 2005, 2006, 2007, 2008, 2009, 2010, 2011
|
||||
;; National Institute of Advanced Industrial Science and Technology (AIST)
|
||||
|
@ -342,15 +344,12 @@ The name of generated file is specified by the variable `ja-dic-filename'."
|
|||
(with-current-buffer buf
|
||||
(erase-buffer)
|
||||
(buffer-disable-undo)
|
||||
(insert ";;; ja-dic.el --- dictionary for Japanese input method"
|
||||
" -*-coding: utf-8; -*-\n"
|
||||
(insert ";;; ja-dic.el --- dictionary for Japanese input method\n"
|
||||
";;\tGenerated by the command `skkdic-convert'\n"
|
||||
";;\tOriginal SKK dictionary file: "
|
||||
(file-relative-name (expand-file-name filename) dirname)
|
||||
"\n\n"
|
||||
";; This file is part of GNU Emacs.\n\n"
|
||||
";;; Commentary:\n\n"
|
||||
";; Do byte-compile this file again after any modification.\n\n"
|
||||
";;; Start of the header of the original SKK dictionary.\n\n")
|
||||
(set-buffer skkbuf)
|
||||
(goto-char 1)
|
||||
|
@ -398,7 +397,13 @@ The name of generated file is specified by the variable `ja-dic-filename'."
|
|||
;; Postfix
|
||||
(with-current-buffer buf
|
||||
(goto-char (point-max))
|
||||
(insert ";;\n(provide 'ja-dic)\n\n;;; ja-dic.el ends here\n")))
|
||||
(insert ";;\n(provide 'ja-dic)\n\n"
|
||||
";; Local Variables:\n"
|
||||
";; version-control: never\n"
|
||||
";; no-update-autoloads: t\n"
|
||||
";; coding: utf-8\n"
|
||||
";; End:\n\n"
|
||||
";;; ja-dic.el ends here\n")))
|
||||
|
||||
;; Save the working buffer.
|
||||
(set-buffer buf)
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue