changeset 107620:2276088a5840

Merge from mainline.
author Eli Zaretskii <eliz@gnu.org>
date Sat, 16 Jan 2010 16:13:12 -0500
parents 41011b06e0aa (current diff) 54435fbb4206 (diff)
children a7af45c06ea9
files admin/notes/commits admin/notes/cvslogs
diffstat 10 files changed, 133 insertions(+), 39 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/admin/notes/commits	Sat Jan 16 16:13:12 2010 -0500
@@ -0,0 +1,53 @@
+HOW TO COMMIT CHANGES TO EMACS
+
+http://lists.gnu.org/archive/html/emacs-devel/2009-03/msg00555.html
+From: 	 Miles Bader
+Subject: commit style redux
+Date: 	 Tue, 31 Mar 2009 12:21:20 +0900
+
+(1) Commit all changed files at once with a single log message (which
+    in CVS will result in an identical log message for all committed
+    files), not one-by-one.  This is pretty easy using vc-dir now.
+
+(2) Make the log message describe the entire changeset, perhaps
+    including relevant changelog entiries (I often don't bother with
+    the latter if it's a trivial sort of change).
+
+    Many modern source-control systems vaguely distinguish the first
+    line of the log message to use as a short summary for abbreviated
+    history listing (in arch this was explicitly called the summary,
+    but many other systems have a similar concept).  So it's nice if
+    you can format the log entry like:
+
+        SHORTISH ONE-LINE SUMMARY
+
+        MULTIPLE-LINE DETAILED DESCRIPTION POSSIBLY INCLUDING (OR
+        CONSISTING OF) CHANGELOG ENTRIES
+
+    [Even with CVS this style is useful, because web CVS browsing
+    interfaces often include the first N words of the log message of
+    the most recent commit as a short "most recent change"
+    description.]
+
+(3) Don't phrase log messages assuming the filename is known, because
+    in non-file-oriented systems (everything modern other than CVS),
+    the log listing tends to be treated as global information, and the
+    connection with specific files is less explicit.
+
+    For instance, currently I often see log messages like "Regenerate";
+    for modern source-control systems with a global log, it's better to
+    have something like "Regenerate configure".
+
+
+Followup discussion:
+http://lists.gnu.org/archive/html/emacs-devel/2010-01/msg00897.html
+
+
+PREVIOUS GUIDELINES FOR CVS
+
+For historical interest only, here is the old-style advice for CVS logs:
+http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg01208.html
+
+From: Eli Zaretskii
+Subject: Re: Log messages in CVS
+Date: Sat, 29 Dec 2007 16:06:29 +0200
--- a/admin/notes/cvslogs	Sat Jan 16 11:11:37 2010 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,15 +0,0 @@
-http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg01208.html
-
-From: Eli Zaretskii
-Subject: Re: Log messages in CVS
-Date: Sat, 29 Dec 2007 16:06:29 +0200
-
-I once posted a summary that I know about; see:
-
-  http://lists.gnu.org/archive/html/emacs-devel/2006-11/msg00229.html
-  http://lists.gnu.org/archive/html/emacs-devel/2006-11/msg00234.html
-  http://lists.gnu.org/archive/html/emacs-devel/2006-11/msg00312.html
-
-Richard commented here, basically approving my summary:
-
-  http://lists.gnu.org/archive/html/emacs-devel/2006-11/msg00276.html
--- a/lisp/ChangeLog	Sat Jan 16 11:11:37 2010 -0500
+++ b/lisp/ChangeLog	Sat Jan 16 16:13:12 2010 -0500
@@ -1,3 +1,14 @@
+2010-01-16  Jari Aalto  <jari.aalto@cante.net>
+
+	* pcmpl-unix.el (pcmpl-unix-read-passwd-file): Doc fix.
+
+2010-01-16  Chong Yidong  <cyd@stupidchicken.com>
+
+	* emacs-lisp/cl-macs.el (defstruct): Doc fix (Bug#5267).
+
+	* startup.el (command-line): Remove unused --icon-type arg.
+	Handle --display arg, passing it to command-line-1 (Bug#5392).
+
 2010-01-16  Mario Lang  <mlang@delysid.org>
 
 	* cedet/ede/cpp-root.el (ede-cpp-root-project):
--- a/lisp/emacs-lisp/cl-loaddefs.el	Sat Jan 16 11:11:37 2010 -0500
+++ b/lisp/emacs-lisp/cl-loaddefs.el	Sat Jan 16 16:13:12 2010 -0500
@@ -282,7 +282,7 @@
 ;;;;;;  flet progv psetq do-all-symbols do-symbols dotimes dolist
 ;;;;;;  do* do loop return-from return block etypecase typecase ecase
 ;;;;;;  case load-time-value eval-when destructuring-bind function*
-;;;;;;  defmacro* defun* gentemp gensym) "cl-macs" "cl-macs.el" "3867c0613dfd69780f561012a1dfe67b")
+;;;;;;  defmacro* defun* gentemp gensym) "cl-macs" "cl-macs.el" "e10a7e42199c08dc39460f67dd2d424b")
 ;;; Generated autoloads from cl-macs.el
 
 (autoload 'gensym "cl-macs" "\
@@ -672,11 +672,21 @@
 
 (autoload 'defstruct "cl-macs" "\
 Define a struct type.
-This macro defines a new Lisp data type called NAME, which contains data
-stored in SLOTs.  This defines a `make-NAME' constructor, a `copy-NAME'
-copier, a `NAME-p' predicate, and setf-able `NAME-SLOT' accessors.
+This macro defines a new data type called NAME that stores data
+in SLOTs.  It defines a `make-NAME' constructor, a `copy-NAME'
+copier, a `NAME-p' predicate, and slot accessors named `NAME-SLOT'.
+You can use the accessors to set the corresponding slots, via `setf'.
 
-\(fn (NAME OPTIONS...) (SLOT SLOT-OPTS...)...)" nil (quote macro))
+NAME may instead take the form (NAME OPTIONS...), where each
+OPTION is either a single keyword or (KEYWORD VALUE).
+See Info node `(cl)Structures' for a list of valid keywords.
+
+Each SLOT may instead take the form (SLOT SLOT-OPTS...), where
+SLOT-OPTS are keyword-value pairs for that slot.  Currently, only
+one keyword is supported, `:read-only'.  If this has a non-nil
+value, that slot cannot be set via `setf'.
+
+\(fn NAME SLOTS...)" nil (quote macro))
 
 (autoload 'cl-struct-setf-expander "cl-macs" "\
 Not documented
--- a/lisp/emacs-lisp/cl-macs.el	Sat Jan 16 11:11:37 2010 -0500
+++ b/lisp/emacs-lisp/cl-macs.el	Sat Jan 16 16:13:12 2010 -0500
@@ -2191,11 +2191,21 @@
 ;;;###autoload
 (defmacro defstruct (struct &rest descs)
   "Define a struct type.
-This macro defines a new Lisp data type called NAME, which contains data
-stored in SLOTs.  This defines a `make-NAME' constructor, a `copy-NAME'
-copier, a `NAME-p' predicate, and setf-able `NAME-SLOT' accessors.
+This macro defines a new data type called NAME that stores data
+in SLOTs.  It defines a `make-NAME' constructor, a `copy-NAME'
+copier, a `NAME-p' predicate, and slot accessors named `NAME-SLOT'.
+You can use the accessors to set the corresponding slots, via `setf'.
 
-\(fn (NAME OPTIONS...) (SLOT SLOT-OPTS...)...)"
+NAME may instead take the form (NAME OPTIONS...), where each
+OPTION is either a single keyword or (KEYWORD VALUE).
+See Info node `(cl)Structures' for a list of valid keywords.
+
+Each SLOT may instead take the form (SLOT SLOT-OPTS...), where
+SLOT-OPTS are keyword-value pairs for that slot.  Currently, only
+one keyword is supported, `:read-only'.  If this has a non-nil
+value, that slot cannot be set via `setf'.
+
+\(fn NAME SLOTS...)"
   (let* ((name (if (consp struct) (car struct) struct))
 	 (opts (cdr-safe struct))
 	 (slots nil)
--- a/lisp/pcmpl-unix.el	Sat Jan 16 11:11:37 2010 -0500
+++ b/lisp/pcmpl-unix.el	Sat Jan 16 16:13:12 2010 -0500
@@ -85,7 +85,10 @@
   (while (pcomplete-here (funcall pcomplete-command-completion-function))))
 
 (defun pcmpl-unix-read-passwd-file (file)
-  "Return an alist correlating gids to group names in FILE."
+  "Return an alist correlating gids to group names in FILE.
+
+If FILE is in hashed format (as described in the OpenSSH
+documentation), this function returns nil."
   (let (names)
     (when (file-readable-p file)
       (with-temp-buffer
--- a/lisp/startup.el	Sat Jan 16 11:11:37 2010 -0500
+++ b/lisp/startup.el	Sat Jan 16 16:13:12 2010 -0500
@@ -758,7 +758,8 @@
       (pop args)))
 
   (let ((done nil)
-	(args (cdr command-line-args)))
+	(args (cdr command-line-args))
+	display-arg)
 
     ;; Figure out which user's init file to load,
     ;; either from the environment or from the options.
@@ -794,6 +795,11 @@
 		(setq argval nil
                       argi orig-argi)))))
 	(cond
+	 ;; The --display arg is handled partly in C, partly in Lisp.
+	 ;; When it shows up here, we just put it back to be handled
+	 ;; by `command-line-1'.
+	 ((member argi '("-d" "-display"))
+	  (setq display-arg (list argi (pop args))))
 	 ((member argi '("-Q" "-quick"))
 	  (setq init-file-user nil
 		site-run-file nil
@@ -813,8 +819,6 @@
 	  (setq init-file-debug t))
 	 ((equal argi "-iconic")
 	  (push '(visibility . icon) initial-frame-alist))
-	 ((member argi '("-icon-type" "-i" "-itype"))
-	  (push '(icon-type . t) default-frame-alist))
 	 ((member argi '("-nbc" "-no-blinking-cursor"))
 	  (setq no-blinking-cursor t))
 	 ;; Push the popped arg back on the list of arguments.
@@ -825,6 +829,9 @@
 	(and argval
 	     (error "Option `%s' doesn't allow an argument" argi))))
 
+    ;; Re-attach the --display arg.
+    (and display-arg (setq args (append display-arg args)))
+
     ;; Re-attach the program name to the front of the arg list.
     (and command-line-args
          (setcdr command-line-args args)))
--- a/src/ChangeLog	Sat Jan 16 11:11:37 2010 -0500
+++ b/src/ChangeLog	Sat Jan 16 16:13:12 2010 -0500
@@ -1,3 +1,12 @@
+2010-01-16  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* xterm.c (event_handler_gdk): Block input (Bug#5037).
+
+2010-01-16  Chong Yidong  <cyd@stupidchicken.com>
+
+	* emacs.c (standard_args): Adjust arg priorities to reflect how
+	they are processed in startup.el.
+
 2010-01-16  Andreas Schwab  <schwab@linux-m68k.org>
 
 	* Makefile.in (lisp, shortlisp): Update.
--- a/src/emacs.c	Sat Jan 16 11:11:37 2010 -0500
+++ b/src/emacs.c	Sat Jan 16 16:13:12 2010 -0500
@@ -1869,7 +1869,7 @@
   /* -d must come last before the options handled in startup.el.  */
   { "-d", "--display", 60, 1 },
   { "-display", 0, 60, 1 },
-  /* Now for the options handled in startup.el.  */
+  /* Now for the options handled in `command-line' (startup.el).  */
   { "-Q", "--quick", 55, 0 },
   { "-quick", 0, 55, 0 },
   { "-q", "--no-init-file", 50, 0 },
@@ -1878,10 +1878,12 @@
   { "-u", "--user", 30, 1 },
   { "-user", 0, 30, 1 },
   { "-debug-init", "--debug-init", 20, 0 },
-  { "-nbi", "--no-bitmap-icon", 15, 0 },
   { "-iconic", "--iconic", 15, 0 },
   { "-D", "--basic-display", 12, 0},
   { "-basic-display", 0, 12, 0},
+  { "-nbc", "--no-blinking-cursor", 12, 0 },
+  /* Now for the options handled in `command-line-1' (startup.el).  */
+  { "-nbi", "--no-bitmap-icon", 10, 0 },
   { "-bg", "--background-color", 10, 1 },
   { "-background", 0, 10, 1 },
   { "-fg", "--foreground-color", 10, 1 },
@@ -1891,7 +1893,6 @@
   { "-ib", "--internal-border", 10, 1 },
   { "-ms", "--mouse-color", 10, 1 },
   { "-cr", "--cursor-color", 10, 1 },
-  { "-nbc", "--no-blinking-cursor", 10, 0 },
   { "-fn", "--font", 10, 1 },
   { "-font", 0, 10, 1 },
   { "-fs", "--fullscreen", 10, 0 },
--- a/src/xterm.c	Sat Jan 16 11:11:37 2010 -0500
+++ b/src/xterm.c	Sat Jan 16 16:13:12 2010 -0500
@@ -5797,6 +5797,7 @@
 {
   XEvent *xev = (XEvent *) gxev;
 
+  BLOCK_INPUT;
   if (current_count >= 0)
     {
       struct x_display_info *dpyinfo;
@@ -5807,23 +5808,27 @@
       /* Filter events for the current X input method.
          GTK calls XFilterEvent but not for key press and release,
          so we do it here.  */
-      if (xev->type == KeyPress || xev->type == KeyRelease)
-        if (dpyinfo && x_filter_event (dpyinfo, xev))
-          return GDK_FILTER_REMOVE;
+      if ((xev->type == KeyPress || xev->type == KeyRelease)
+	  && dpyinfo
+	  && x_filter_event (dpyinfo, xev))
+	{
+	  UNBLOCK_INPUT;
+	  return GDK_FILTER_REMOVE;
+	}
 #endif
 
       if (! dpyinfo)
         current_finish = X_EVENT_NORMAL;
       else
-	{
-	  current_count +=
-	    handle_one_xevent (dpyinfo, xev, &current_finish,
-			       current_hold_quit);
-	}
+	current_count +=
+	  handle_one_xevent (dpyinfo, xev, &current_finish,
+			     current_hold_quit);
     }
   else
     current_finish = x_dispatch_event (xev, xev->xany.display);
 
+  UNBLOCK_INPUT;
+
   if (current_finish == X_EVENT_GOTO_OUT || current_finish == X_EVENT_DROP)
     return GDK_FILTER_REMOVE;