Now on revision 109409. ------------------------------------------------------------ revno: 109409 committer: Tassilo Horn branch nick: trunk timestamp: Fri 2012-08-03 08:47:32 +0200 message: * textmodes/reftex.el (reftex-compile-variables): Make keyvals labels regex position point at the expected place. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-08-03 02:49:51 +0000 +++ lisp/ChangeLog 2012-08-03 06:47:32 +0000 @@ -1,3 +1,8 @@ +2012-08-03 Tassilo Horn + + * textmodes/reftex.el (reftex-compile-variables): Make keyvals + labels regex position point at the expected place. + 2012-08-03 MON KEY * net/imap.el (imap-interactive-login, imap-authenticate) === modified file 'lisp/textmodes/reftex.el' --- lisp/textmodes/reftex.el 2012-07-27 17:58:58 +0000 +++ lisp/textmodes/reftex.el 2012-08-03 06:47:32 +0000 @@ -1291,7 +1291,7 @@ ;; keyvals [..., label = {foo}, ...] ;; forms used by ctable, listings, ;; minted, ... - "\\[[^]]*label[[:space:]]*=[[:space:]]*{?\\(?1:[^],}]+\\)}?[^[]*\\]" + "\\[[^]]*label[[:space:]]*=[[:space:]]*{?\\(?1:[^],}]+\\)}?" "\\)")) (include-re (concat wbol "\\\\\\(" ------------------------------------------------------------ revno: 109408 author: MON KEY committer: Chong Yidong branch nick: trunk timestamp: Fri 2012-08-03 10:49:51 +0800 message: Doc fixes for imap.el. * net/imap.el (imap-interactive-login, imap-authenticate) (imap-mailbox-lsub, imap-mailbox-list) (imap-mailbox-status-asynch, imap-mailbox-acl-delete) (imap-fetch, imap-message-flag-permanent-p, imap-envelope-from) (imap-parse-response): Doc fix. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-08-03 02:29:59 +0000 +++ lisp/ChangeLog 2012-08-03 02:49:51 +0000 @@ -1,3 +1,11 @@ +2012-08-03 MON KEY + + * net/imap.el (imap-interactive-login, imap-authenticate) + (imap-mailbox-lsub, imap-mailbox-list) + (imap-mailbox-status-asynch, imap-mailbox-acl-delete) + (imap-fetch, imap-message-flag-permanent-p, imap-envelope-from) + (imap-parse-response): Doc fix. + 2012-08-03 João Távora * textmodes/tex-mode.el (latex-forward-sexp): Terminate the loop === modified file 'lisp/net/imap.el' --- lisp/net/imap.el 2012-04-09 13:05:48 +0000 +++ lisp/net/imap.el 2012-08-03 02:49:51 +0000 @@ -68,7 +68,7 @@ ;; imap-body-lines ;; ;; It is my hope that these commands should be pretty self -;; explanatory for someone that know IMAP. All functions have +;; explanatory for someone who knows IMAP. All functions have ;; additional documentation on how to invoke them. ;; ;; imap.el supports RFC1730/2060/RFC3501 (IMAP4/IMAP4rev1). The implemented @@ -838,9 +838,10 @@ (defun imap-interactive-login (buffer loginfunc) "Login to server in BUFFER. -LOGINFUNC is passed a username and a password, it should return t if -it where successful authenticating itself to the server, nil otherwise. -Returns t if login was successful, nil otherwise." +Return t if login was successful, nil otherwise. + +LOGINFUNC is passed a username and a password. It should return +t if it successfully authenticates, nil otherwise." (with-current-buffer buffer (make-local-variable 'imap-username) (make-local-variable 'imap-password) @@ -1187,11 +1188,12 @@ (defun imap-authenticate (&optional user passwd buffer) "Authenticate to server in BUFFER, using current buffer if nil. -It uses the authenticator specified when opening the server. If the -authenticator requires username/passwords, they are queried from the -user and optionally stored in the buffer. If USER and/or PASSWD is -specified, the user will not be questioned and the username and/or -password is remembered in the buffer." +It uses the authenticator specified when opening the server. + +Optional arguments USER and PASSWD specify the username and +password to use if the authenticator requires a username and/or +password. If omitted or nil, the authenticator may query the +user for a username and/or password." (with-current-buffer (or buffer (current-buffer)) (if (not (eq imap-state 'nonauth)) (or (eq imap-state 'auth) @@ -1475,7 +1477,7 @@ (defun imap-mailbox-lsub (&optional root reference add-delimiter buffer) "Return a list of subscribed mailboxes on server in BUFFER. If ROOT is non-nil, only list matching mailboxes. If ADD-DELIMITER is -non-nil, a hierarchy delimiter is added to root. REFERENCE is a +non-nil, a hierarchy delimiter is added to root. REFERENCE is an implementation-specific string that has to be passed to lsub command." (with-current-buffer (or buffer (current-buffer)) ;; Make sure we know the hierarchy separator for root's hierarchy @@ -1499,7 +1501,7 @@ (defun imap-mailbox-list (root &optional reference add-delimiter buffer) "Return a list of mailboxes matching ROOT on server in BUFFER. If ADD-DELIMITER is non-nil, a hierarchy delimiter is added to -root. REFERENCE is a implementation-specific string that has to be +root. REFERENCE is an implementation-specific string that has to be passed to list command." (with-current-buffer (or buffer (current-buffer)) ;; Make sure we know the hierarchy separator for root's hierarchy @@ -1559,7 +1561,7 @@ (imap-mailbox-get items mailbox))))) (defun imap-mailbox-status-asynch (mailbox items &optional buffer) - "Send status item request ITEM on MAILBOX to server in BUFFER. + "Send status item requests ITEMS on MAILBOX to server in BUFFER. ITEMS can be a symbol or a list of symbols, valid symbols are one of the STATUS data items -- i.e. 'messages, 'recent, 'uidnext, 'uidvalidity or 'unseen. The IMAP command tag is returned." @@ -1596,7 +1598,7 @@ rights)))))) (defun imap-mailbox-acl-delete (identifier &optional mailbox buffer) - "Remove any pair for IDENTIFIER in MAILBOX from server in BUFFER." + "Remove pairs for IDENTIFIER from MAILBOX on server in BUFFER." (let ((mailbox (imap-utf7-encode mailbox))) (with-current-buffer (or buffer (current-buffer)) (imap-ok-p @@ -1642,8 +1644,8 @@ (defun imap-fetch (uids props &optional receive nouidfetch buffer) "Fetch properties PROPS from message set UIDS from server in BUFFER. -UIDS can be a string, number or a list of numbers. If RECEIVE -is non-nil return these properties." +UIDS can be a string, number or a list of numbers. If RECEIVE is +non-nil, return these properties." (with-current-buffer (or buffer (current-buffer)) (when (imap-ok-p (imap-send-command-wait (format "%sFETCH %s %s" (if nouidfetch "" "UID ") @@ -1743,7 +1745,8 @@ (imap-mailbox-get-1 'search imap-current-mailbox))))) (defun imap-message-flag-permanent-p (flag &optional mailbox buffer) - "Return t if FLAG can be permanently (between IMAP sessions) saved on articles, in MAILBOX on server in BUFFER." + "Return t if FLAG can be permanently saved on articles. +MAILBOX specifies a mailbox on the server in BUFFER." (with-current-buffer (or buffer (current-buffer)) (or (member "\\*" (imap-mailbox-get 'permanentflags mailbox)) (member flag (imap-mailbox-get 'permanentflags mailbox))))) @@ -1918,7 +1921,7 @@ 0)) (defun imap-envelope-from (from) - "Return a from string line." + "Return a FROM string line." (and from (concat (aref from 0) (if (aref from 0) " <") @@ -2285,7 +2288,7 @@ ;; ; capability. (defun imap-parse-response () - "Parse a IMAP command response." + "Parse an IMAP command response." (let (token) (case (setq token (read (current-buffer))) (+ (setq imap-continuation ------------------------------------------------------------ revno: 109407 fixes bug: http://debbugs.gnu.org/5734 author: João Távora committer: Chong Yidong branch nick: trunk timestamp: Fri 2012-08-03 10:29:59 +0800 message: Workaround for latex-forward-sexp slowness. * textmodes/tex-mode.el (latex-forward-sexp): Terminate the loop if sexp scanning does not move point. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-08-02 19:04:53 +0000 +++ lisp/ChangeLog 2012-08-03 02:29:59 +0000 @@ -1,3 +1,8 @@ +2012-08-03 João Távora + + * textmodes/tex-mode.el (latex-forward-sexp): Terminate the loop + if sexp scanning does not move point (Bug#5734). + 2012-08-02 Tassilo Horn * textmodes/reftex-vars.el (reftex-default-label-alist-entries): === modified file 'lisp/textmodes/tex-mode.el' --- lisp/textmodes/tex-mode.el 2012-07-17 08:11:31 +0000 +++ lisp/textmodes/tex-mode.el 2012-08-03 02:29:59 +0000 @@ -1722,9 +1722,12 @@ "Like `forward-sexp' but aware of multi-char elements and escaped parens." (interactive "P") (unless arg (setq arg 1)) - (let ((pos (point))) + (let ((pos (point)) + (opoint 0)) (condition-case err - (while (/= arg 0) + (while (and (/= (point) opoint) + (/= arg 0)) + (setq opoint (point)) (setq arg (if (> arg 0) (progn (latex-forward-sexp-1) (1- arg)) ------------------------------------------------------------ revno: 109406 committer: Paul Eggert branch nick: trunk timestamp: Thu 2012-08-02 17:42:11 -0700 message: Merge from gnulib. 2012-08-02 stat-time, timespec, u64: support naive out-of-dir builds diff: === modified file 'ChangeLog' --- ChangeLog 2012-08-02 10:39:47 +0000 +++ ChangeLog 2012-08-03 00:42:11 +0000 @@ -1,3 +1,8 @@ +2012-08-03 Paul Eggert + + Merge from gnulib, incorporating: + 2012-08-02 stat-time, timespec, u64: support naive out-of-dir builds + 2012-08-02 YAMAMOTO Mitsuharu * lib/Makefile.am (DEFAULT_INCLUDES): Add -I$(top_srcdir)/lib for === modified file 'lib/stat-time.c' --- lib/stat-time.c 2012-08-02 04:46:10 +0000 +++ lib/stat-time.c 2012-08-03 00:42:11 +0000 @@ -1,3 +1,3 @@ #include #define _GL_STAT_TIME_INLINE _GL_EXTERN_INLINE -#include +#include "stat-time.h" === modified file 'lib/timespec.c' --- lib/timespec.c 2012-08-02 04:46:10 +0000 +++ lib/timespec.c 2012-08-03 00:42:11 +0000 @@ -1,3 +1,3 @@ #include #define _GL_TIMESPEC_INLINE _GL_EXTERN_INLINE -#include +#include "timespec.h" === modified file 'lib/u64.c' --- lib/u64.c 2012-08-02 04:46:10 +0000 +++ lib/u64.c 2012-08-03 00:42:11 +0000 @@ -1,3 +1,3 @@ #include #define _GL_U64_INLINE _GL_EXTERN_INLINE -#include +#include "u64.h" ------------------------------------------------------------ revno: 109405 fixes bug: http://debbugs.gnu.org/12118 committer: Paul Eggert branch nick: trunk timestamp: Thu 2012-08-02 13:59:49 -0700 message: Fix macroexp crash on Windows with debugging. * lisp.h (ASET) [ENABLE_CHECKING]: Ignore ARRAY_MARK_FLAG when checking subscripts; problem introduced with the recent "ASET (a, i, v)" rather than "AREF (a, i) = v" patch. (ARRAY_MARK_FLAG): Now a macro as well as a constant, since it's used in non-static inline functions now. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-08-02 10:49:19 +0000 +++ src/ChangeLog 2012-08-02 20:59:49 +0000 @@ -1,5 +1,12 @@ 2012-08-02 Paul Eggert + Fix macroexp crash on Windows with debugging (Bug#12118). + * lisp.h (ASET) [ENABLE_CHECKING]: Ignore ARRAY_MARK_FLAG when + checking subscripts; problem introduced with the recent + "ASET (a, i, v)" rather than "AREF (a, i) = v" patch. + (ARRAY_MARK_FLAG): Now a macro as well as a constant, + since it's used in non-static inline functions now. + * xfaces.c (face_at_buffer_position, face_for_overlay_string): Don't assume buffer size fits in 'int'. Remove unused local. === modified file 'src/lisp.h' --- src/lisp.h 2012-08-02 10:49:19 +0000 +++ src/lisp.h 2012-08-02 20:59:49 +0000 @@ -331,7 +331,9 @@ /* In the size word of a vector, this bit means the vector has been marked. */ -static ptrdiff_t const ARRAY_MARK_FLAG = PTRDIFF_MIN; +static ptrdiff_t const ARRAY_MARK_FLAG +#define ARRAY_MARK_FLAG PTRDIFF_MIN + = ARRAY_MARK_FLAG; /* In the size word of a struct Lisp_Vector, this bit means it's really some other vector-like object. */ @@ -606,7 +608,7 @@ /* The IDX==IDX tries to detect when the macro argument is side-effecting. */ #define ASET(ARRAY, IDX, VAL) \ (eassert ((IDX) == (IDX)), \ - eassert ((IDX) >= 0 && (IDX) < ASIZE (ARRAY)), \ + eassert ((IDX) >= 0 && (IDX) < (ASIZE (ARRAY) & ~ARRAY_MARK_FLAG)), \ XVECTOR (ARRAY)->contents[IDX] = (VAL)) /* Convenience macros for dealing with Lisp strings. */ ------------------------------------------------------------ revno: 109404 committer: Tassilo Horn branch nick: trunk timestamp: Thu 2012-08-02 21:04:53 +0200 message: fixup ChangeLog diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-08-02 18:54:36 +0000 +++ lisp/ChangeLog 2012-08-02 19:04:53 +0000 @@ -1,13 +1,10 @@ -2012-08-02 Tassilo Horn - - * textmodes/reftex-vars.el (reftex-label-alist): Docfix. - 2012-08-02 Tassilo Horn * textmodes/reftex-vars.el (reftex-default-label-alist-entries): Add listings, minted, and ctable packages. (reftex-label-alist-builtin): Move listings, minted, and ctable entries before LaTeX. + (reftex-label-alist): Docfix. 2012-08-02 Bastien Guerry ------------------------------------------------------------ revno: 109403 committer: Tassilo Horn branch nick: trunk timestamp: Thu 2012-08-02 20:54:36 +0200 message: * textmodes/reftex-vars.el (reftex-label-alist): Docfix. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-08-02 18:24:11 +0000 +++ lisp/ChangeLog 2012-08-02 18:54:36 +0000 @@ -1,3 +1,7 @@ +2012-08-02 Tassilo Horn + + * textmodes/reftex-vars.el (reftex-label-alist): Docfix. + 2012-08-02 Tassilo Horn * textmodes/reftex-vars.el (reftex-default-label-alist-entries): === modified file 'lisp/textmodes/reftex-vars.el' --- lisp/textmodes/reftex-vars.el 2012-08-02 18:24:11 +0000 +++ lisp/textmodes/reftex-vars.el 2012-08-02 18:54:36 +0000 @@ -91,13 +91,13 @@ (("wrapfigure" ?f nil nil caption))) (ctable "The ctable package" - (("\\ctable[]{}{}{}" ?t "tab:" "\\ref{%s}" 1 ("table" "Tabelle")))) + (("\\ctable[]{}{}{}" ?t "tab:" "\\ref{%s}" 1 ("table" "Tabelle")))) (listings "The listings package" - (("lstlisting" ?l "lst:" "~\\ref{%s}" nil (regexp "[Ll]isting")))) + (("lstlisting" ?l "lst:" "~\\ref{%s}" nil (regexp "[Ll]isting")))) (minted "The minted package" - (("minted" ?l "lst:" "~\\ref{%s}" nil (regexp "[Ll]isting")))) + (("minted" ?l "lst:" "~\\ref{%s}" nil (regexp "[Ll]isting")))) ;; The LaTeX core stuff (LaTeX "LaTeX default environments" @@ -584,7 +584,7 @@ Any list entry may also be a symbol. If that has an association in `reftex-label-alist-builtin', the cddr of that association is spliced into the list. However, builtin defaults should normally be set with the variable -`reftex-default-label-alist-entries." +`reftex-default-label-alist-entries'." :group 'reftex-defining-label-environments :set 'reftex-set-dirty :type ------------------------------------------------------------ revno: 109402 committer: Tassilo Horn branch nick: trunk timestamp: Thu 2012-08-02 20:24:11 +0200 message: * textmodes/reftex-vars.el (reftex-default-label-alist-entries): Add listings, minted, and ctable packages. (reftex-label-alist-builtin): Move listings, minted, and ctable entries before LaTeX. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-08-02 16:54:42 +0000 +++ lisp/ChangeLog 2012-08-02 18:24:11 +0000 @@ -1,3 +1,10 @@ +2012-08-02 Tassilo Horn + + * textmodes/reftex-vars.el (reftex-default-label-alist-entries): + Add listings, minted, and ctable packages. + (reftex-label-alist-builtin): Move listings, minted, and ctable + entries before LaTeX. + 2012-08-02 Bastien Guerry * replace.el (occur): Fix docstring (bug#12122). === modified file 'lisp/textmodes/reftex-vars.el' --- lisp/textmodes/reftex-vars.el 2012-07-27 07:59:50 +0000 +++ lisp/textmodes/reftex-vars.el 2012-08-02 18:24:11 +0000 @@ -90,6 +90,15 @@ (wrapfig "The wrapfigure environment" (("wrapfigure" ?f nil nil caption))) + (ctable "The ctable package" + (("\\ctable[]{}{}{}" ?t "tab:" "\\ref{%s}" 1 ("table" "Tabelle")))) + + (listings "The listings package" + (("lstlisting" ?l "lst:" "~\\ref{%s}" nil (regexp "[Ll]isting")))) + + (minted "The minted package" + (("minted" ?l "lst:" "~\\ref{%s}" nil (regexp "[Ll]isting")))) + ;; The LaTeX core stuff (LaTeX "LaTeX default environments" (("section" ?s "%S" "~\\ref{%s}" (nil . t) @@ -120,16 +129,7 @@ ;; The label macro is hard coded, but it *could* be defined like this: ;;("\\label{*}" nil nil nil nil) - )) - - (ctable "The ctable package" - (("\\ctable[]{}{}{}" ?t "tab:" "\\ref{%s}" 1 ("table" "Tabelle")))) - - (listings "The listings package" - (("lstlisting" ?l "lst:" "~\\ref{%s}" nil (regexp "[Ll]isting")))) - - (minted "The minted package" - (("minted" ?l "lst:" "~\\ref{%s}" nil (regexp "[Ll]isting"))))) + ))) "The default label environment descriptions. Lower-case symbols correspond to a style file of the same name in the LaTeX distribution. Mixed-case symbols are convenience aliases.") @@ -430,7 +430,8 @@ (defcustom reftex-default-label-alist-entries '(amsmath endnotes fancybox floatfig longtable picinpar - rotating sidecap subfigure supertab wrapfig LaTeX) + rotating sidecap subfigure supertab wrapfig + listings minted ctable LaTeX) "Default label alist specifications. LaTeX should always be the last entry. The value of this variable is a list of symbols with associations in the constant `reftex-label-alist-builtin'. Check that constant for a full list ------------------------------------------------------------ revno: 109401 committer: Bastien Guerry branch nick: trunk timestamp: Thu 2012-08-02 18:54:42 +0200 message: Fix typo in docstring. Bug #12122. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-08-02 06:19:48 +0000 +++ lisp/ChangeLog 2012-08-02 16:54:42 +0000 @@ -1,3 +1,7 @@ +2012-08-02 Bastien Guerry + + * replace.el (occur): Fix docstring (bug#12122). + 2012-08-02 Glenn Morris * emacs-lisp/authors.el (authors-renamed-files-alist): Add ms-w32.h. === modified file 'lisp/replace.el' --- lisp/replace.el 2012-06-27 21:15:13 +0000 +++ lisp/replace.el 2012-08-02 16:54:42 +0000 @@ -1140,8 +1140,8 @@ For example, providing \"defun\\s +\\(\\S +\\)\" for REGEXP and \"\\1\" for NLINES collects all the function names in a lisp program. When there is no parenthesized subexpressions in REGEXP -the entire match is collected. In any case the searched buffers -are not modified." +the entire match is collected. In any case the searched buffer +is not modified." (interactive (occur-read-primary-args)) (occur-1 regexp nlines (list (current-buffer)))) ------------------------------------------------------------ revno: 109400 committer: Paul Eggert branch nick: trunk timestamp: Thu 2012-08-02 03:49:19 -0700 message: * lisp.h (VALMASK) [!USE_LSB_TAG]: Now a macro as well as a constant, since it's used in non-static inline functions now. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-08-02 09:33:13 +0000 +++ src/ChangeLog 2012-08-02 10:49:19 +0000 @@ -30,6 +30,7 @@ (INLINE_HEADER_END): New macros. * lisp.h (PSEUDOVECTOR_FLAG): Now a macro as well as a constant, since it's used in non-static inline functions now. + (VALMASK) [!USE_LSB_TAG]: Likewise. 2012-08-02 Glenn Morris === modified file 'src/lisp.h' --- src/lisp.h 2012-08-02 07:31:34 +0000 +++ src/lisp.h 2012-08-02 10:49:19 +0000 @@ -423,7 +423,9 @@ #else /* not USE_LSB_TAG */ -static EMACS_INT const VALMASK = VAL_MAX; +static EMACS_INT const VALMASK +#define VALMASK VAL_MAX + = VALMASK; #define XTYPE(a) ((enum Lisp_Type) ((EMACS_UINT) XLI (a) >> VALBITS)) ------------------------------------------------------------ revno: 109399 committer: YAMAMOTO Mitsuharu branch nick: trunk timestamp: Thu 2012-08-02 19:39:47 +0900 message: * lib/Makefile.am (DEFAULT_INCLUDES): Add -I$(top_srcdir)/lib for out-of-tree build. diff: === modified file 'ChangeLog' --- ChangeLog 2012-08-02 06:21:48 +0000 +++ ChangeLog 2012-08-02 10:39:47 +0000 @@ -1,3 +1,8 @@ +2012-08-02 YAMAMOTO Mitsuharu + + * lib/Makefile.am (DEFAULT_INCLUDES): Add -I$(top_srcdir)/lib for + out-of-tree build. + 2012-08-02 Glenn Morris * make-dist: Remove src/s. === modified file 'lib/Makefile.am' --- lib/Makefile.am 2012-04-09 07:45:59 +0000 +++ lib/Makefile.am 2012-08-02 10:39:47 +0000 @@ -5,6 +5,6 @@ noinst_LIBRARIES = AM_CFLAGS = $(GNULIB_WARN_CFLAGS) $(WERROR_CFLAGS) -DEFAULT_INCLUDES = -I. -I../src -I$(top_srcdir)/src +DEFAULT_INCLUDES = -I. -I$(top_srcdir)/lib -I../src -I$(top_srcdir)/src include gnulib.mk ------------------------------------------------------------ revno: 109398 committer: Glenn Morris branch nick: trunk timestamp: Thu 2012-08-02 06:17:32 -0400 message: Auto-commit of generated files. diff: === modified file 'autogen/Makefile.in' --- autogen/Makefile.in 2012-08-01 10:17:30 +0000 +++ autogen/Makefile.in 2012-08-02 10:17:32 +0000 @@ -66,9 +66,9 @@ $(top_srcdir)/m4/alloca.m4 $(top_srcdir)/m4/c-strtod.m4 \ $(top_srcdir)/m4/clock_time.m4 $(top_srcdir)/m4/dup2.m4 \ $(top_srcdir)/m4/environ.m4 $(top_srcdir)/m4/extensions.m4 \ - $(top_srcdir)/m4/filemode.m4 $(top_srcdir)/m4/getloadavg.m4 \ - $(top_srcdir)/m4/getopt.m4 $(top_srcdir)/m4/gettime.m4 \ - $(top_srcdir)/m4/gettimeofday.m4 \ + $(top_srcdir)/m4/extern-inline.m4 $(top_srcdir)/m4/filemode.m4 \ + $(top_srcdir)/m4/getloadavg.m4 $(top_srcdir)/m4/getopt.m4 \ + $(top_srcdir)/m4/gettime.m4 $(top_srcdir)/m4/gettimeofday.m4 \ $(top_srcdir)/m4/gnulib-common.m4 \ $(top_srcdir)/m4/gnulib-comp.m4 \ $(top_srcdir)/m4/include_next.m4 $(top_srcdir)/m4/inttypes.m4 \ @@ -111,16 +111,17 @@ am__libgnu_a_SOURCES_DIST = allocator.c c-ctype.h c-ctype.c \ c-strcase.h c-strcasecmp.c c-strncasecmp.c careadlinkat.c \ md5.c sha1.c sha256.c sha512.c dtoastr.c dtotimespec.c \ - filemode.c gettext.h gettime.c strftime.c timespec-add.c \ - timespec-sub.c utimens.c + filemode.c gettext.h gettime.c stat-time.c strftime.c \ + timespec.c timespec-add.c timespec-sub.c u64.c utimens.c am__objects_1 = am_libgnu_a_OBJECTS = allocator.$(OBJEXT) c-ctype.$(OBJEXT) \ c-strcasecmp.$(OBJEXT) c-strncasecmp.$(OBJEXT) \ careadlinkat.$(OBJEXT) md5.$(OBJEXT) sha1.$(OBJEXT) \ sha256.$(OBJEXT) sha512.$(OBJEXT) dtoastr.$(OBJEXT) \ dtotimespec.$(OBJEXT) filemode.$(OBJEXT) $(am__objects_1) \ - gettime.$(OBJEXT) strftime.$(OBJEXT) timespec-add.$(OBJEXT) \ - timespec-sub.$(OBJEXT) utimens.$(OBJEXT) + gettime.$(OBJEXT) stat-time.$(OBJEXT) strftime.$(OBJEXT) \ + timespec.$(OBJEXT) timespec-add.$(OBJEXT) \ + timespec-sub.$(OBJEXT) u64.$(OBJEXT) utimens.$(OBJEXT) libgnu_a_OBJECTS = $(am_libgnu_a_OBJECTS) depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp am__depfiles_maybe = depfiles @@ -878,8 +879,8 @@ libgnu_a_SOURCES = allocator.c c-ctype.h c-ctype.c c-strcase.h \ c-strcasecmp.c c-strncasecmp.c careadlinkat.c md5.c sha1.c \ sha256.c sha512.c dtoastr.c dtotimespec.c filemode.c \ - $(am__append_1) gettime.c strftime.c timespec-add.c \ - timespec-sub.c utimens.c + $(am__append_1) gettime.c stat-time.c strftime.c timespec.c \ + timespec-add.c timespec-sub.c u64.c utimens.c libgnu_a_LIBADD = $(gl_LIBOBJS) libgnu_a_DEPENDENCIES = $(gl_LIBOBJS) EXTRA_libgnu_a_SOURCES = ftoastr.c dup2.c getloadavg.c getopt.c \ @@ -968,6 +969,7 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sha1.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sha256.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sha512.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stat-time.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stat.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strftime.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strtoimax.Po@am__quote@ @@ -980,6 +982,8 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/time_r.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timespec-add.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timespec-sub.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timespec.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/u64.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/utimens.Po@am__quote@ .c.o: === modified file 'autogen/aclocal.m4' --- autogen/aclocal.m4 2012-07-29 10:19:06 +0000 +++ autogen/aclocal.m4 2012-08-02 10:17:32 +0000 @@ -991,6 +991,7 @@ m4_include([m4/dup2.m4]) m4_include([m4/environ.m4]) m4_include([m4/extensions.m4]) +m4_include([m4/extern-inline.m4]) m4_include([m4/filemode.m4]) m4_include([m4/getloadavg.m4]) m4_include([m4/getopt.m4]) === modified file 'autogen/config.in' --- autogen/config.in 2012-08-01 10:17:30 +0000 +++ autogen/config.in 2012-08-02 10:17:32 +0000 @@ -128,6 +128,9 @@ we did ioctl TIOCSCTTY). */ #undef DONT_REOPEN_PTY +/* Define if the system is MS DOS or MS Windows. */ +#undef DOS_NT + /* Define to 1 if you are using the GNU C Library. */ #undef DOUG_LEA_MALLOC @@ -1150,6 +1153,9 @@ /* Define to support POP mail retrieval. */ #undef MAIL_USE_POP +/* Define if the system is MS DOS. */ +#undef MSDOS + /* Define if system's imake configuration file defines `NeedWidePrototypes' as `NO'. */ #undef NARROWPROTO @@ -1416,9 +1422,6 @@ # endif #endif -/* Some platforms redefine this. */ -#undef WRETCODE - /* Define this to check for malloc buffer overrun. */ #undef XMALLOC_OVERRUN_CHECK @@ -1530,6 +1533,35 @@ configuration information. */ #undef config_opsysfile +/* _GL_INLINE is a portable alternative to ISO C99 plain 'inline'. + _GL_EXTERN_INLINE is a portable alternative to 'extern inline'. + _GL_INLINE_HEADER_BEGIN contains useful stuff to put + in an include file, before uses of _GL_INLINE. + It suppresses GCC's bogus "no previous prototype for 'FOO'" diagnostic, + when FOO is an inline function in the header; see + . + _GL_INLINE_HEADER_END contains useful stuff to put + in the same include file, after uses of _GL_INLINE. */ +#if __GNUC__ ? __GNUC_STDC_INLINE__ : 199901L <= __STDC_VERSION__ +# define _GL_INLINE inline +# define _GL_EXTERN_INLINE extern inline +# if (__GNUC__ == 4 && 6 <= __GNUC_MINOR__) || 4 < __GNUC__ +# define _GL_INLINE_HEADER_BEGIN \ + _Pragma ("GCC diagnostic push") \ + _Pragma ("GCC diagnostic ignored \"-Wmissing-prototypes\"") +# define _GL_INLINE_HEADER_END \ + _Pragma ("GCC diagnostic pop") +# endif +#else +# define _GL_INLINE static inline +# define _GL_EXTERN_INLINE static inline +#endif + +#ifndef _GL_INLINE_HEADER_BEGIN +# define _GL_INLINE_HEADER_BEGIN +# define _GL_INLINE_HEADER_END +#endif + /* A replacement for va_copy, if needed. */ #define gl_va_copy(a,b) ((a) = (b)) @@ -1632,9 +1664,6 @@ /* Define as `fork' if `vfork' does not work. */ #undef vfork -/* Some platforms redefine this. */ -#undef wait3 - #include #endif /* EMACS_CONFIG_H */ === modified file 'autogen/configure' --- autogen/configure 2012-08-01 10:17:30 +0000 +++ autogen/configure 2012-08-02 10:17:32 +0000 @@ -6945,6 +6945,7 @@ # Code from module environ: # Code from module extensions: + # Code from module extern-inline: # Code from module filemode: # Code from module getloadavg: # Code from module getopt-gnu: @@ -15229,17 +15230,6 @@ ;; esac -case $opsys in - irix6-5 | sol2* | unixware ) - -$as_echo "#define wait3(status, options, rusage) waitpid ((pid_t) -1, (status), (options))" >>confdefs.h - - -$as_echo "#define WRETCODE(w) (w >> 8)" >>confdefs.h - - ;; -esac - case $opsys in hpux* | sol2* ) @@ -15262,6 +15252,8 @@ + + case $opsys in aix4-2) $as_echo "#define USG /**/" >>confdefs.h @@ -16358,6 +16350,10 @@ HAVE_DECL_ENVIRON=0 fi + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; } if test "${ac_cv_struct_st_dm_mode+set}" = set; then : @@ -19999,6 +19995,7 @@ + # Persuade glibc to declare getloadavg(). @@ -23139,7 +23136,6 @@ - if test $gl_cv_have_include_next = yes; then gl_cv_next_unistd_h='<'unistd.h'>' else ------------------------------------------------------------ revno: 109397 committer: Paul Eggert branch nick: trunk timestamp: Thu 2012-08-02 02:33:13 -0700 message: * xfaces.c (face_for_overlay_string): Remove unused local. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-08-02 09:20:01 +0000 +++ src/ChangeLog 2012-08-02 09:33:13 +0000 @@ -1,8 +1,7 @@ 2012-08-02 Paul Eggert - * xfaces.c (face_at_buffer_position): Remove unused local. - (face_at_buffer_position, face_for_overlay_string): - Don't assume buffer size fits in 'int'. + * xfaces.c (face_at_buffer_position, face_for_overlay_string): + Don't assume buffer size fits in 'int'. Remove unused local. Use C99-style 'extern inline' if available. * buffer.h (BUFFER_INLINE): === modified file 'src/xfaces.c' --- src/xfaces.c 2012-08-02 09:20:01 +0000 +++ src/xfaces.c 2012-08-02 09:33:13 +0000 @@ -6144,7 +6144,6 @@ struct frame *f = XFRAME (WVAR (w, frame)); Lisp_Object attrs[LFACE_VECTOR_SIZE]; Lisp_Object prop, position; - Lisp_Object frame; ptrdiff_t endpos; Lisp_Object propname = mouse ? Qmouse_face : Qface; Lisp_Object limit1, end; @@ -6154,7 +6153,6 @@ to use the frame and buffer of W, but right now it doesn't. */ /* eassert (XBUFFER (w->buffer) == current_buffer); */ - XSETFRAME (frame, f); XSETFASTINT (position, pos); endpos = ZV; ------------------------------------------------------------ revno: 109396 committer: Paul Eggert branch nick: trunk timestamp: Thu 2012-08-02 02:20:01 -0700 message: * xfaces.c: Don't assume buffer size fits in 'int'. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-08-02 08:47:07 +0000 +++ src/ChangeLog 2012-08-02 09:20:01 +0000 @@ -1,6 +1,8 @@ 2012-08-02 Paul Eggert * xfaces.c (face_at_buffer_position): Remove unused local. + (face_at_buffer_position, face_for_overlay_string): + Don't assume buffer size fits in 'int'. Use C99-style 'extern inline' if available. * buffer.h (BUFFER_INLINE): === modified file 'src/xfaces.c' --- src/xfaces.c 2012-08-02 08:47:07 +0000 +++ src/xfaces.c 2012-08-02 09:20:01 +0000 @@ -6101,7 +6101,7 @@ for (i = 0; i < noverlays; i++) { Lisp_Object oend; - int oendpos; + ptrdiff_t oendpos; prop = Foverlay_get (overlay_vec[i], propname); if (!NILP (prop)) @@ -6145,7 +6145,7 @@ Lisp_Object attrs[LFACE_VECTOR_SIZE]; Lisp_Object prop, position; Lisp_Object frame; - int endpos; + ptrdiff_t endpos; Lisp_Object propname = mouse ? Qmouse_face : Qface; Lisp_Object limit1, end; struct face *default_face; ------------------------------------------------------------ revno: 109395 committer: Paul Eggert branch nick: trunk timestamp: Thu 2012-08-02 01:47:07 -0700 message: * xfaces.c (face_at_buffer_position): Remove unused local. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-08-02 07:31:34 +0000 +++ src/ChangeLog 2012-08-02 08:47:07 +0000 @@ -1,5 +1,7 @@ 2012-08-02 Paul Eggert + * xfaces.c (face_at_buffer_position): Remove unused local. + Use C99-style 'extern inline' if available. * buffer.h (BUFFER_INLINE): * category.h (CATEGORY_INLINE): === modified file 'src/xfaces.c' --- src/xfaces.c 2012-08-01 20:51:44 +0000 +++ src/xfaces.c 2012-08-02 08:47:07 +0000 @@ -6036,7 +6036,6 @@ Lisp_Object prop, position; ptrdiff_t i, noverlays; Lisp_Object *overlay_vec; - Lisp_Object frame; ptrdiff_t endpos; Lisp_Object propname = mouse ? Qmouse_face : Qface; Lisp_Object limit1, end; @@ -6046,7 +6045,6 @@ to use the frame and buffer of W, but right now it doesn't. */ /* eassert (XBUFFER (w->buffer) == current_buffer); */ - XSETFRAME (frame, f); XSETFASTINT (position, pos); endpos = ZV; ------------------------------------------------------------ revno: 109394 committer: Chong Yidong branch nick: trunk timestamp: Thu 2012-08-02 16:12:36 +0800 message: lisp/emacs-lisp/rx.el: Remove dead URL from commentary. diff: === modified file 'lisp/emacs-lisp/rx.el' --- lisp/emacs-lisp/rx.el 2012-01-19 07:21:25 +0000 +++ lisp/emacs-lisp/rx.el 2012-08-02 08:12:36 +0000 @@ -35,9 +35,8 @@ ;; that the `repeat' form can't have multiple regexp args. ;; Now alternative forms are provided for a degree of compatibility -;; with Shivers' attempted definitive SRE notation -;; . SRE forms not -;; catered for include: dsm, uncase, w/case, w/nocase, ,@, +;; with Olin Shivers' attempted definitive SRE notation. SRE forms +;; not catered for include: dsm, uncase, w/case, w/nocase, ,@, ;; ,, (word ...), word+, posix-string, and character class forms. ;; Some forms are inconsistent with SRE, either for historical reasons ;; or because of the implementation -- simple translation into Emacs ------------------------------------------------------------ revno: 109393 committer: Paul Eggert branch nick: trunk timestamp: Thu 2012-08-02 00:31:34 -0700 message: Use C99-style 'extern inline' if available. * lib-src/profile.c (SYSTIME_INLINE): Define. * nt/config.nt: Sync with autogen/config.in. (_GL_INLINE, _GL_EXTERN_INLINE, _GL_INLINE_HEADER_BEGIN) (_GL_INLINE_HEADER_END): New macros. * src/buffer.h (BUFFER_INLINE): * src/category.h (CATEGORY_INLINE): * src/character.h (CHARACTER_INLINE): * src/charset.h (CHARSET_INLINE): * src/composite.h (COMPOSITE_INLINE): * src/dispextern.h (DISPEXTERN_INLINE): * src/lisp.h (LISP_INLINE): * src/systime.h (SYSTIME_INLINE): New macro, replacing 'static inline' in this header. * src/buffer.h, src/category.h, src/character.h, src/charset.h: * src/composite.h, src/dispextern.h, lisp.h, systime.h: Use INLINE_HEADER_BEGIN, INLINE_HEADER_END. * src/alloc.c (LISP_INLINE): * src/buffer.c (BUFFER_INLINE): * src/category.c (CATEGORY_INLINE): * src/character.c (CHARACTER_INLINE): * src/charset.c (CHARSET_INLINE): * src/composite.c (COMPOSITE_INLINE): * src/dispnew.c (DISPEXTERN_INLINE): * src/sysdep.c (SYSTIME_INLINE): Define to EXTERN_INLINE, so that the corresponding functions are compiled into code. * src/conf_post.h (INLINE, EXTERN_INLINE, INLINE_HEADER_BEGIN) (INLINE_HEADER_END): New macros. * src/lisp.h (PSEUDOVECTOR_FLAG): Now a macro as well as a constant, since it's used in non-static inline functions now. diff: === modified file 'lib-src/ChangeLog' --- lib-src/ChangeLog 2012-08-02 06:19:48 +0000 +++ lib-src/ChangeLog 2012-08-02 07:31:34 +0000 @@ -1,3 +1,8 @@ +2012-08-02 Paul Eggert + + Use C99-style 'extern inline' if available. + * profile.c (SYSTIME_INLINE): Define. + 2012-08-02 Glenn Morris * makefile.w32-in (MS_W32_H): Update for new ms-w32.h location. === modified file 'lib-src/profile.c' --- lib-src/profile.c 2012-07-10 23:24:36 +0000 +++ lib-src/profile.c 2012-08-02 07:31:34 +0000 @@ -30,6 +30,8 @@ */ #include +#define SYSTIME_INLINE EXTERN_INLINE + #include #include === modified file 'nt/ChangeLog' --- nt/ChangeLog 2012-08-02 06:19:48 +0000 +++ nt/ChangeLog 2012-08-02 07:31:34 +0000 @@ -1,3 +1,10 @@ +2012-08-02 Paul Eggert + + Use C99-style 'extern inline' if available. + * config.nt: Sync with autogen/config.in. + (_GL_INLINE, _GL_EXTERN_INLINE, _GL_INLINE_HEADER_BEGIN) + (_GL_INLINE_HEADER_END): New macros. + 2012-08-02 Glenn Morris * inc/ms-w32.h: Move here from ../src/s. === modified file 'nt/config.nt' --- nt/config.nt 2012-08-02 06:19:48 +0000 +++ nt/config.nt 2012-08-02 07:31:34 +0000 @@ -1540,6 +1540,35 @@ configuration information. */ #define config_opsysfile +/* _GL_INLINE is a portable alternative to ISO C99 plain 'inline'. + _GL_EXTERN_INLINE is a portable alternative to 'extern inline'. + _GL_INLINE_HEADER_BEGIN contains useful stuff to put + in an include file, before uses of _GL_INLINE. + It suppresses GCC's bogus "no previous prototype for 'FOO'" diagnostic, + when FOO is an inline function in the header; see + . + _GL_INLINE_HEADER_END contains useful stuff to put + in the same include file, after uses of _GL_INLINE. */ +#if __GNUC__ ? __GNUC_STDC_INLINE__ : 199901L <= __STDC_VERSION__ +# define _GL_INLINE inline +# define _GL_EXTERN_INLINE extern inline +# if (__GNUC__ == 4 && 6 <= __GNUC_MINOR__) || 4 < __GNUC__ +# define _GL_INLINE_HEADER_BEGIN \ + _Pragma ("GCC diagnostic push") \ + _Pragma ("GCC diagnostic ignored \"-Wmissing-prototypes\"") +# define _GL_INLINE_HEADER_END \ + _Pragma ("GCC diagnostic pop") +# endif +#else +# define _GL_INLINE static inline +# define _GL_EXTERN_INLINE static inline +#endif + +#ifndef _GL_INLINE_HEADER_BEGIN +# define _GL_INLINE_HEADER_BEGIN +# define _GL_INLINE_HEADER_END +#endif + /* A replacement for va_copy, if needed. */ #define gl_va_copy(a,b) ((a) = (b)) === modified file 'src/ChangeLog' --- src/ChangeLog 2012-08-02 06:21:48 +0000 +++ src/ChangeLog 2012-08-02 07:31:34 +0000 @@ -1,3 +1,33 @@ +2012-08-02 Paul Eggert + + Use C99-style 'extern inline' if available. + * buffer.h (BUFFER_INLINE): + * category.h (CATEGORY_INLINE): + * character.h (CHARACTER_INLINE): + * charset.h (CHARSET_INLINE): + * composite.h (COMPOSITE_INLINE): + * dispextern.h (DISPEXTERN_INLINE): + * lisp.h (LISP_INLINE): + * systime.h (SYSTIME_INLINE): + New macro, replacing 'static inline' in this header. + * buffer.h, category.h, character.h, charset.h, composite.h: + * dispextern.h, lisp.h, systime.h: + Use INLINE_HEADER_BEGIN, INLINE_HEADER_END. + * alloc.c (LISP_INLINE): + * buffer.c (BUFFER_INLINE): + * category.c (CATEGORY_INLINE): + * character.c (CHARACTER_INLINE): + * charset.c (CHARSET_INLINE): + * composite.c (COMPOSITE_INLINE): + * dispnew.c (DISPEXTERN_INLINE): + * sysdep.c (SYSTIME_INLINE): + Define to EXTERN_INLINE, so that the corresponding functions + are compiled into code. + * conf_post.h (INLINE, EXTERN_INLINE, INLINE_HEADER_BEGIN) + (INLINE_HEADER_END): New macros. + * lisp.h (PSEUDOVECTOR_FLAG): Now a macro as well as a constant, + since it's used in non-static inline functions now. + 2012-08-02 Glenn Morris * s/: Remove empty directory. === modified file 'src/alloc.c' --- src/alloc.c 2012-08-01 08:49:28 +0000 +++ src/alloc.c 2012-08-02 07:31:34 +0000 @@ -19,6 +19,9 @@ along with GNU Emacs. If not, see . */ #include + +#define LISP_INLINE EXTERN_INLINE + #include #include /* For CHAR_BIT. */ #include === modified file 'src/buffer.c' --- src/buffer.c 2012-08-01 08:49:28 +0000 +++ src/buffer.c 2012-08-02 07:31:34 +0000 @@ -19,6 +19,8 @@ #include +#define BUFFER_INLINE EXTERN_INLINE + #include #include #include === modified file 'src/buffer.h' --- src/buffer.h 2012-08-01 08:49:28 +0000 +++ src/buffer.h 2012-08-02 07:31:34 +0000 @@ -21,6 +21,11 @@ #include /* for off_t, time_t */ #include "systime.h" /* for EMACS_TIME */ +INLINE_HEADER_BEGIN +#ifndef BUFFER_INLINE +# define BUFFER_INLINE INLINE +#endif + /* Accessing the parameters of the current buffer. */ /* These macros come in pairs, one for the char position @@ -961,7 +966,7 @@ the buffer to the next character after fetching this one. Instead, use either FETCH_CHAR_ADVANCE or STRING_CHAR_AND_LENGTH. */ -static inline int +BUFFER_INLINE int FETCH_MULTIBYTE_CHAR (ptrdiff_t pos) { unsigned char *p = ((pos >= GPT_BYTE ? GAP_SIZE : 0) @@ -973,7 +978,7 @@ If POS doesn't point the head of valid multi-byte form, only the byte at POS is returned. No range checking. */ -static inline int +BUFFER_INLINE int BUF_FETCH_MULTIBYTE_CHAR (struct buffer *buf, ptrdiff_t pos) { unsigned char *p @@ -1090,7 +1095,7 @@ (*(Lisp_Object *)((OFFSET) + (char *) (BUFFER))) /* Downcase a character C, or make no change if that cannot be done. */ -static inline int +BUFFER_INLINE int downcase (int c) { Lisp_Object downcase_table = BVAR (current_buffer, downcase_table); @@ -1099,10 +1104,10 @@ } /* 1 if C is upper case. */ -static inline int uppercasep (int c) { return downcase (c) != c; } +BUFFER_INLINE int uppercasep (int c) { return downcase (c) != c; } /* Upcase a character C known to be not upper case. */ -static inline int +BUFFER_INLINE int upcase1 (int c) { Lisp_Object upcase_table = BVAR (current_buffer, upcase_table); @@ -1111,8 +1116,10 @@ } /* 1 if C is lower case. */ -static inline int lowercasep (int c) +BUFFER_INLINE int lowercasep (int c) { return !uppercasep (c) && upcase1 (c) != c; } /* Upcase a character C, or make no change if that cannot be done. */ -static inline int upcase (int c) { return uppercasep (c) ? c : upcase1 (c); } +BUFFER_INLINE int upcase (int c) { return uppercasep (c) ? c : upcase1 (c); } + +INLINE_HEADER_END === modified file 'src/category.c' --- src/category.c 2012-06-16 12:24:15 +0000 +++ src/category.c 2012-08-02 07:31:34 +0000 @@ -29,6 +29,9 @@ table. Read comments in the file category.h to understand them. */ #include + +#define CATEGORY_INLINE EXTERN_INLINE + #include #include #include "lisp.h" === modified file 'src/category.h' --- src/category.h 2012-06-16 08:20:19 +0000 +++ src/category.h 2012-08-02 07:31:34 +0000 @@ -53,6 +53,11 @@ The second extra slot is a version number of the category table. But, for the moment, we are not using this slot. */ +INLINE_HEADER_BEGIN +#ifndef CATEGORY_INLINE +# define CATEGORY_INLINE INLINE +#endif + #define CATEGORYP(x) RANGED_INTEGERP (0x20, x, 0x7E) #define CHECK_CATEGORY(x) \ @@ -79,7 +84,7 @@ >> ((category) % 8)) & 1) /* Return 1 if category set of CH contains CATEGORY, else return 0. */ -static inline int +CATEGORY_INLINE int CHAR_HAS_CATEGORY (int ch, int category) { Lisp_Object category_set = CATEGORY_SET (ch); @@ -108,3 +113,5 @@ && word_boundary_p (c1, c2)) extern int word_boundary_p (int, int); + +INLINE_HEADER_END === modified file 'src/character.c' --- src/character.c 2012-07-16 04:47:31 +0000 +++ src/character.c 2012-08-02 07:31:34 +0000 @@ -29,6 +29,8 @@ #include #endif +#define CHARACTER_INLINE EXTERN_INLINE + #include #ifdef emacs === modified file 'src/character.h' --- src/character.h 2012-07-09 16:38:45 +0000 +++ src/character.h 2012-08-02 07:31:34 +0000 @@ -25,6 +25,11 @@ #include +INLINE_HEADER_BEGIN +#ifndef CHARACTER_INLINE +# define CHARACTER_INLINE INLINE +#endif + /* character code 1st byte byte sequence -------------- -------- ------------- 0-7F 00..7F 0xxxxxxx @@ -570,7 +575,7 @@ #define SANE_TAB_WIDTH(buf) \ sanitize_tab_width (XFASTINT (BVAR (buf, tab_width))) -static inline int +CHARACTER_INLINE int sanitize_tab_width (EMACS_INT width) { return 0 < width && width <= 1000 ? width : 8; @@ -591,7 +596,7 @@ /* Return a non-outlandish value for a character width. */ -static inline int +CHARACTER_INLINE int sanitize_char_width (EMACS_INT width) { return 0 <= width && width <= 1000 ? width : 1000; @@ -695,4 +700,6 @@ #define GET_TRANSLATION_TABLE(id) \ (XCDR(XVECTOR(Vtranslation_table_vector)->contents[(id)])) +INLINE_HEADER_END + #endif /* EMACS_CHARACTER_H */ === modified file 'src/charset.c' --- src/charset.c 2012-08-01 20:51:44 +0000 +++ src/charset.c 2012-08-02 07:31:34 +0000 @@ -26,6 +26,8 @@ #include +#define CHARSET_INLINE EXTERN_INLINE + #include #include #include === modified file 'src/charset.h' --- src/charset.h 2012-08-01 20:51:44 +0000 +++ src/charset.h 2012-08-02 07:31:34 +0000 @@ -29,6 +29,11 @@ #include +INLINE_HEADER_BEGIN +#ifndef CHARSET_INLINE +# define CHARSET_INLINE INLINE +#endif + /* Index to arguments of Fdefine_charset_internal. */ enum define_charset_arg_index @@ -325,7 +330,7 @@ #define CHARSET_DEUNIFIER(charset) \ (CHARSET_ATTR_DEUNIFIER (CHARSET_ATTRIBUTES (charset))) -static inline void +CHARSET_INLINE void set_charset_attr (struct charset *charset, enum charset_attr_index idx, Lisp_Object val) { @@ -541,4 +546,6 @@ Lisp_Object, Lisp_Object, struct charset *, unsigned, unsigned); +INLINE_HEADER_END + #endif /* EMACS_CHARSET_H */ === modified file 'src/composite.c' --- src/composite.c 2012-08-01 20:51:44 +0000 +++ src/composite.c 2012-08-02 07:31:34 +0000 @@ -23,6 +23,9 @@ along with GNU Emacs. If not, see . */ #include + +#define COMPOSITE_INLINE EXTERN_INLINE + #include #include "lisp.h" #include "character.h" === modified file 'src/composite.h' --- src/composite.h 2012-08-01 20:51:44 +0000 +++ src/composite.h 2012-08-02 07:31:34 +0000 @@ -25,6 +25,11 @@ #ifndef EMACS_COMPOSITE_H #define EMACS_COMPOSITE_H +INLINE_HEADER_BEGIN +#ifndef COMPOSITE_INLINE +# define COMPOSITE_INLINE INLINE +#endif + /* Methods to display a sequence of components of a composition. */ enum composition_method { /* Compose relatively without alternate characters. */ @@ -247,7 +252,7 @@ #define LGSTRING_GLYPH_LEN(lgs) (ASIZE ((lgs)) - 2) #define LGSTRING_GLYPH(lgs, idx) AREF ((lgs), (idx) + 2) #define LGSTRING_SET_GLYPH(lgs, idx, val) ASET ((lgs), (idx) + 2, (val)) -static inline Lisp_Object * +COMPOSITE_INLINE Lisp_Object * lgstring_glyph_addr (Lisp_Object lgs, ptrdiff_t idx) { return aref_addr (lgs, idx + 2); @@ -321,4 +326,6 @@ extern ptrdiff_t composition_adjust_point (ptrdiff_t, ptrdiff_t); +INLINE_HEADER_END + #endif /* not EMACS_COMPOSITE_H */ === modified file 'src/conf_post.h' --- src/conf_post.h 2012-08-01 15:33:09 +0000 +++ src/conf_post.h 2012-08-02 07:31:34 +0000 @@ -213,4 +213,9 @@ #undef noinline #endif +#define INLINE _GL_INLINE +#define EXTERN_INLINE _GL_EXTERN_INLINE +#define INLINE_HEADER_BEGIN _GL_INLINE_HEADER_BEGIN +#define INLINE_HEADER_END _GL_INLINE_HEADER_END + /* conf_post.h ends here */ === modified file 'src/dispextern.h' --- src/dispextern.h 2012-08-01 05:11:36 +0000 +++ src/dispextern.h 2012-08-02 07:31:34 +0000 @@ -46,8 +46,13 @@ #include "msdos.h" #endif +INLINE_HEADER_BEGIN +#ifndef DISPEXTERN_INLINE +# define DISPEXTERN_INLINE INLINE +#endif + #include -static inline int +DISPEXTERN_INLINE int xstrcasecmp (char const *a, char const *b) { return c_strcasecmp (a, b); @@ -3400,4 +3405,6 @@ #endif /* HAVE_WINDOW_SYSTEM */ +INLINE_HEADER_END + #endif /* not DISPEXTERN_H_INCLUDED */ === modified file 'src/dispnew.c' --- src/dispnew.c 2012-08-01 05:11:36 +0000 +++ src/dispnew.c 2012-08-02 07:31:34 +0000 @@ -18,6 +18,9 @@ along with GNU Emacs. If not, see . */ #include + +#define DISPEXTERN_INLINE EXTERN_INLINE + #include #include #include === modified file 'src/lisp.h' --- src/lisp.h 2012-08-01 20:51:44 +0000 +++ src/lisp.h 2012-08-02 07:31:34 +0000 @@ -28,6 +28,11 @@ #include +INLINE_HEADER_BEGIN +#ifndef LISP_INLINE +# define LISP_INLINE INLINE +#endif + /* The ubiquitous max and min macros. */ #undef min #undef max @@ -295,14 +300,14 @@ typedef struct { EMACS_INT i; } Lisp_Object; #define XLI(o) (o).i -static inline Lisp_Object +LISP_INLINE Lisp_Object XIL (EMACS_INT i) { Lisp_Object o = { i }; return o; } -static inline Lisp_Object +LISP_INLINE Lisp_Object LISP_MAKE_RVALUE (Lisp_Object o) { return o; @@ -330,7 +335,9 @@ /* In the size word of a struct Lisp_Vector, this bit means it's really some other vector-like object. */ -static ptrdiff_t const PSEUDOVECTOR_FLAG = PTRDIFF_MAX - PTRDIFF_MAX / 2; +static ptrdiff_t const PSEUDOVECTOR_FLAG +#define PSEUDOVECTOR_FLAG (PTRDIFF_MAX - PTRDIFF_MAX / 2) + = PSEUDOVECTOR_FLAG; /* In a pseudovector, the size field actually contains a word with one PSEUDOVECTOR_FLAG bit set, and exactly one of the following bits to @@ -480,7 +487,7 @@ #define FIXNUM_OVERFLOW_P(i) \ (! ((0 <= (i) || MOST_NEGATIVE_FIXNUM <= (i)) && (i) <= MOST_POSITIVE_FIXNUM)) -static inline ptrdiff_t +LISP_INLINE ptrdiff_t clip_to_bounds (ptrdiff_t lower, EMACS_INT num, ptrdiff_t upper) { return num < lower ? lower : num <= upper ? num : upper; @@ -2338,37 +2345,37 @@ /* Simple access functions. */ -static inline Lisp_Object * +LISP_INLINE Lisp_Object * aref_addr (Lisp_Object array, ptrdiff_t idx) { return & XVECTOR (array)->contents[idx]; } -static inline void +LISP_INLINE void set_hash_key (struct Lisp_Hash_Table *h, ptrdiff_t idx, Lisp_Object val) { ASET (h->key_and_value, 2 * idx, val); } -static inline void +LISP_INLINE void set_hash_value (struct Lisp_Hash_Table *h, ptrdiff_t idx, Lisp_Object val) { ASET (h->key_and_value, 2 * idx + 1, val); } -static inline void +LISP_INLINE void set_hash_next (struct Lisp_Hash_Table *h, ptrdiff_t idx, Lisp_Object val) { ASET (h->next, idx, val); } -static inline void +LISP_INLINE void set_hash_hash (struct Lisp_Hash_Table *h, ptrdiff_t idx, Lisp_Object val) { ASET (h->hash, idx, val); } -static inline void +LISP_INLINE void set_hash_index (struct Lisp_Hash_Table *h, ptrdiff_t idx, Lisp_Object val) { ASET (h->index, idx, val); @@ -2692,7 +2699,7 @@ /* Make unibyte string from C string when the length isn't known. */ -static inline Lisp_Object +LISP_INLINE Lisp_Object build_unibyte_string (const char *str) { return make_unibyte_string (str, strlen (str)); @@ -2710,7 +2717,7 @@ /* Make a string allocated in pure space, use STR as string data. */ -static inline Lisp_Object +LISP_INLINE Lisp_Object build_pure_c_string (const char *str) { return make_pure_c_string (str, strlen (str)); @@ -2719,7 +2726,7 @@ /* Make a string from the data at STR, treating it as multibyte if the data warrants. */ -static inline Lisp_Object +LISP_INLINE Lisp_Object build_string (const char *str) { return make_string (str, strlen (str)); @@ -2838,13 +2845,13 @@ extern void init_lread (void); extern void syms_of_lread (void); -static inline Lisp_Object +LISP_INLINE Lisp_Object intern (const char *str) { return intern_1 (str, strlen (str)); } -static inline Lisp_Object +LISP_INLINE Lisp_Object intern_c_string (const char *str) { return intern_c_string_1 (str, strlen (str)); @@ -3493,7 +3500,7 @@ /* Check whether it's time for GC, and run it if so. */ -static inline void +LISP_INLINE void maybe_gc (void) { if ((consing_since_gc > gc_cons_threshold @@ -3503,4 +3510,6 @@ Fgarbage_collect (); } +INLINE_HEADER_END + #endif /* EMACS_LISP_H */ === modified file 'src/sysdep.c' --- src/sysdep.c 2012-08-02 04:14:48 +0000 +++ src/sysdep.c 2012-08-02 07:31:34 +0000 @@ -18,6 +18,9 @@ along with GNU Emacs. If not, see . */ #include + +#define SYSTIME_INLINE EXTERN_INLINE + #include #include #include === modified file 'src/systime.h' --- src/systime.h 2012-07-14 11:32:01 +0000 +++ src/systime.h 2012-08-02 07:31:34 +0000 @@ -21,6 +21,11 @@ #include +INLINE_HEADER_BEGIN +#ifndef SYSTIME_INLINE +# define SYSTIME_INLINE INLINE +#endif + #ifdef emacs # ifdef HAVE_X_WINDOWS # include @@ -54,12 +59,12 @@ /* EMACS_SECS (TIME) is the seconds component of TIME. EMACS_NSECS (TIME) is the nanoseconds component of TIME. emacs_secs_addr (PTIME) is the address of *PTIME's seconds component. */ -static inline time_t EMACS_SECS (EMACS_TIME t) { return t.tv_sec; } -static inline int EMACS_NSECS (EMACS_TIME t) { return t.tv_nsec; } -static inline time_t *emacs_secs_addr (EMACS_TIME *t) { return &t->tv_sec; } +SYSTIME_INLINE time_t EMACS_SECS (EMACS_TIME t) { return t.tv_sec; } +SYSTIME_INLINE int EMACS_NSECS (EMACS_TIME t) { return t.tv_nsec; } +SYSTIME_INLINE time_t *emacs_secs_addr (EMACS_TIME *t) { return &t->tv_sec; } /* Return an Emacs time with seconds S and nanoseconds NS. */ -static inline EMACS_TIME +SYSTIME_INLINE EMACS_TIME make_emacs_time (time_t s, int ns) { EMACS_TIME r = { s, ns }; @@ -67,7 +72,7 @@ } /* Return an invalid Emacs time. */ -static inline EMACS_TIME +SYSTIME_INLINE EMACS_TIME invalid_emacs_time (void) { EMACS_TIME r = { 0, -1 }; @@ -75,7 +80,7 @@ } /* Return current system time. */ -static inline EMACS_TIME +SYSTIME_INLINE EMACS_TIME current_emacs_time (void) { EMACS_TIME r; @@ -92,12 +97,12 @@ be used with their first argument an absolute time since the epoch and the second argument a non-negative offset. Do NOT use them for anything else. */ -static inline EMACS_TIME +SYSTIME_INLINE EMACS_TIME add_emacs_time (EMACS_TIME a, EMACS_TIME b) { return timespec_add (a, b); } -static inline EMACS_TIME +SYSTIME_INLINE EMACS_TIME sub_emacs_time (EMACS_TIME a, EMACS_TIME b) { return timespec_sub (a, b); @@ -106,14 +111,14 @@ /* Return the sign of the valid time stamp TIME, either -1, 0, or 1. Note: this can only return a negative value if time_t is a signed data type. */ -static inline int +SYSTIME_INLINE int EMACS_TIME_SIGN (EMACS_TIME t) { return timespec_sign (t); } /* Return 1 if TIME is a valid time stamp. */ -static inline int +SYSTIME_INLINE int EMACS_TIME_VALID_P (EMACS_TIME t) { return 0 <= t.tv_nsec; @@ -123,14 +128,14 @@ On overflow, return an extremal value; in particular, if time_t is an unsigned data type and D is negative, return zero. Return the minimum EMACS_TIME if D is not a number. */ -static inline EMACS_TIME +SYSTIME_INLINE EMACS_TIME EMACS_TIME_FROM_DOUBLE (double d) { return dtotimespec (d); } /* Convert the Emacs time T to an approximate double value D. */ -static inline double +SYSTIME_INLINE double EMACS_TIME_TO_DOUBLE (EMACS_TIME t) { return timespectod (t); @@ -155,35 +160,37 @@ #endif /* Compare times T1 and T2 for equality, inequality etc. */ -static inline int +SYSTIME_INLINE int EMACS_TIME_EQ (EMACS_TIME t1, EMACS_TIME t2) { return timespec_cmp (t1, t2) == 0; } -static inline int +SYSTIME_INLINE int EMACS_TIME_NE (EMACS_TIME t1, EMACS_TIME t2) { return timespec_cmp (t1, t2) != 0; } -static inline int +SYSTIME_INLINE int EMACS_TIME_GT (EMACS_TIME t1, EMACS_TIME t2) { return timespec_cmp (t1, t2) > 0; } -static inline int +SYSTIME_INLINE int EMACS_TIME_GE (EMACS_TIME t1, EMACS_TIME t2) { return timespec_cmp (t1, t2) >= 0; } -static inline int +SYSTIME_INLINE int EMACS_TIME_LT (EMACS_TIME t1, EMACS_TIME t2) { return timespec_cmp (t1, t2) < 0; } -static inline int +SYSTIME_INLINE int EMACS_TIME_LE (EMACS_TIME t1, EMACS_TIME t2) { return timespec_cmp (t1, t2) <= 0; } +INLINE_HEADER_END + #endif /* EMACS_SYSTIME_H */ ------------------------------------------------------------ revno: 109392 committer: Glenn Morris branch nick: trunk timestamp: Wed 2012-08-01 23:47:17 -0700 message: Misc updates for CPP-DEFINES diff: === modified file 'admin/CPP-DEFINES' --- admin/CPP-DEFINES 2012-08-02 04:14:48 +0000 +++ admin/CPP-DEFINES 2012-08-02 06:47:17 +0000 @@ -1,10 +1,21 @@ Here are some of the cpp macros used, together with some short explanation of their use. Feel free to add more macros and more categories. +Most of these are from config.in, so it's probably better to put the +explanations in that file. Ideally, everything would be defined and +documented in config.in, and this file would not be necessary. + ** Distinguishing OSes ** +AIX +_AIX +BSD4_2 +BSD_SYSTEM CYGWIN Compiling the Cygwin port. __CYGWIN__ Ditto +GNU_LINUX +HPUX +IRIX6_5 MSDOS Compiling the MS-DOS port. __MSDOS__ Ditto. __DJGPP_MINOR__ Minor version number of the DJGPP library; used only in msdos.c and dosfns.c. @@ -13,6 +24,10 @@ __MINGW32__ Compiling the W32 port with the MinGW port of GCC. _MSC_VER Compiling the W32 port with the Microsoft C compiler. DARWIN_OS Compiling on Mac OS X or pure Darwin (and using s/darwin.h). +SOLARIS2 +USG +USG5 +USG5_4 ** Distinguishing GUIs ** @@ -45,12 +60,12 @@ REL_ALLOC Compile in the relocatable memory allocator ralloc.c. SYSTEM_MALLOC Use the system library's malloc. -subprocesses System can use subprocesses (for M-x shell for example). Defined by default, only MSDOS undefines it. -DEBUG_LISP_OBJECT_TYPE Define it in lisp.h enable compile time checks on Lisp_Object use. +subprocesses System can use subprocesses (for M-x shell for example). + Defined by default, only MSDOS undefines it. +DEBUG_LISP_OBJECT_TYPE Define it in lisp.h enable compile time checks + on Lisp_Object use. -** System specific macros, described in detail in src/s/template.h -CLASH_DETECTION -COFF +** System specific macros FIRST_PTY_LETTER HAVE_PTYS INTERRUPT_INPUT @@ -59,12 +74,12 @@ SYSTEM_TYPE ** Misc macros -USER_FULL_NAME If defined, overrides the default pw->pw_gecos for getting at the full user name. Only MSDOS overrides the default. - -** Defines from src/s/*.h. Some of these might not be used in the code anymore, so they can be removed. The HAVE_* definitions are probably handled by autoconf, so it might be possible to just remove them from src/s/*.h. - - -AIX +USER_FULL_NAME If defined, overrides the default pw->pw_gecos for +getting at the full user name. Only MSDOS overrides the default. + +** Miscellaneous defines. Some of these might not be used in the code +anymore, so they can be removed. + AMPERSAND_FULL_NAME BROKEN_DATAGRAM_SOCKETS BROKEN_FIONREAD @@ -76,8 +91,6 @@ BROKEN_SIGIO BROKEN_SIGPOLL BROKEN_SIGPTY -BSD4_2 -BSD_SYSTEM CLASH_DETECTION DATA_SEG_BITS DATA_START @@ -100,7 +113,6 @@ GC_SETJMP_WORKS GMALLOC_INHIBIT_VALLOC GNU_LIBRARY_PENDING_OUTPUT_COUNT -GNU_LINUX GNU_MALLOC HAVE_AIX_SMT_EXP HAVE_CBRT @@ -159,20 +171,16 @@ HAVE_WINDOW_SYSTEM HAVE_WORKING_VFORK HAVE_XRMSETDATABASE -HPUX INTERNAL_TERMINAL IS_ANY_SEP IS_DIRECTORY_SEP -LINKER LINUX_VERSION_CODE -LNOFLSH LOCALTIME_CACHE MAIL_USE_FLOCK MAIL_USE_LOCKF MAIL_USE_POP MAIL_USE_SYSTEM_LOCK MAXPATHLEN -MIN_PTY_KERNEL_VERSION -- only used on Mac MODE_LINE_BINARY_TEXT MUST_UNDEF__STDC__ NLIST_STRUCT @@ -208,7 +216,6 @@ SIGPIPE SIGQUIT SIGTRAP -SOLARIS2 STDC_HEADERS SYSTEM_PURESIZE_EXTRA SYSTEM_MALLOC @@ -223,13 +230,9 @@ UNIX98_PTYS USE_CRT_DLL USE_TOOLKIT_SCROLL_BARS -USG -USG5 USG_SUBTTY_WORKS VALBITS XOS_NEEDS_TIME_H -_AIX -_ARCH_PPC64 _FILE_OFFSET_BITS _LP64 _MALLOC_INTERNAL