changeset 87903:5d58981e6690

Merge from emacs--rel--22 Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1006
author Miles Bader <miles@gnu.org>
date Tue, 22 Jan 2008 23:53:46 +0000
parents 2080d155f7aa (current diff) dbb6bb5288bf (diff)
children db83d2a010da
files ChangeLog admin/FOR-RELEASE admin/make-tarball.txt doc/emacs/abbrevs.texi doc/emacs/ack.texi doc/emacs/anti.texi doc/emacs/arevert-xtra.texi doc/emacs/basic.texi doc/emacs/buffers.texi doc/emacs/building.texi doc/emacs/cal-xtra.texi doc/emacs/calendar.texi doc/emacs/cmdargs.texi doc/emacs/commands.texi doc/emacs/custom.texi doc/emacs/dired-xtra.texi doc/emacs/dired.texi doc/emacs/display.texi doc/emacs/emacs-xtra.texi doc/emacs/emacs.texi doc/emacs/emerge-xtra.texi doc/emacs/entering.texi doc/emacs/files.texi doc/emacs/fixit.texi doc/emacs/fortran-xtra.texi doc/emacs/frames.texi doc/emacs/glossary.texi doc/emacs/gnu.texi doc/emacs/help.texi doc/emacs/indent.texi doc/emacs/killing.texi doc/emacs/kmacro.texi doc/emacs/m-x.texi doc/emacs/macos.texi doc/emacs/maintaining.texi doc/emacs/major.texi doc/emacs/mark.texi doc/emacs/mini.texi doc/emacs/misc.texi doc/emacs/msdog-xtra.texi doc/emacs/msdog.texi doc/emacs/mule.texi doc/emacs/picture-xtra.texi doc/emacs/programs.texi doc/emacs/regs.texi doc/emacs/rmail.texi doc/emacs/screen.texi doc/emacs/search.texi doc/emacs/sending.texi doc/emacs/text.texi doc/emacs/trouble.texi doc/emacs/vc-xtra.texi doc/emacs/vc1-xtra.texi doc/emacs/vc2-xtra.texi doc/emacs/windows.texi doc/emacs/xresources.texi doc/lispref/ChangeLog doc/lispref/buffers.texi doc/misc/Makefile.in doc/misc/ada-mode.texi doc/misc/autotype.texi doc/misc/calc.texi doc/misc/cc-mode.texi doc/misc/cl.texi doc/misc/dired-x.texi doc/misc/ebrowse.texi doc/misc/ediff.texi doc/misc/emacs-mime.texi doc/misc/erc.texi doc/misc/eshell.texi doc/misc/eudc.texi doc/misc/faq.texi doc/misc/flymake.texi doc/misc/forms.texi doc/misc/gnus-faq.texi doc/misc/idlwave.texi doc/misc/info.texi doc/misc/makefile.w32-in doc/misc/mh-e.texi doc/misc/newsticker.texi doc/misc/pcl-cvs.texi doc/misc/pgg.texi doc/misc/rcirc.texi doc/misc/reftex.texi doc/misc/sc.texi doc/misc/ses.texi doc/misc/sieve.texi doc/misc/smtpmail.texi doc/misc/speedbar.texi doc/misc/texinfo.tex doc/misc/trampver.texi doc/misc/url.texi doc/misc/vip.texi doc/misc/viper.texi doc/misc/widget.texi doc/misc/woman.texi etc/NEWS.22 etc/images/mail/README leim/ChangeLog leim/quail/latin-ltx.el lisp/ChangeLog lisp/ChangeLog.12 lisp/comint.el lisp/files.el lisp/frame.el lisp/progmodes/ada-mode.el lisp/progmodes/ada-xref.el lisp/progmodes/cc-vars.el lisp/progmodes/ebrowse.el lisp/progmodes/gdb-ui.el lisp/progmodes/sh-script.el lisp/progmodes/verilog-mode.el lisp/subr.el lisp/url/ChangeLog lisp/url/url-handlers.el lisp/vc-arch.el lisp/vc-hg.el lisp/vc-svn.el lisp/view.el lisp/whitespace.el nt/ChangeLog src/ChangeLog src/fns.c src/mac.c src/macterm.c src/macterm.h src/w32term.c src/xterm.c
diffstat 132 files changed, 1047 insertions(+), 898 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Tue Jan 22 15:44:14 2008 +0000
+++ b/ChangeLog	Tue Jan 22 23:53:46 2008 +0000
@@ -1,3 +1,7 @@
+2008-01-21  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* config.guess, config.sub: Updated from master source.
+
 2008-01-17  Andreas Schwab  <schwab@suse.de>
 
 	* configure.in (HAVE_LIB64_DIR): Rename from HAVE_X86_64_LIB64_DIR.
--- a/admin/FOR-RELEASE	Tue Jan 22 15:44:14 2008 +0000
+++ b/admin/FOR-RELEASE	Tue Jan 22 23:53:46 2008 +0000
@@ -36,6 +36,11 @@
 ** henman@it.to-be.co.jp 09 Aug 2006: ispell.el problem on Cygwin.
   (Did we decide that is unreproducible?)
 
+** lennart.borgman@gmail.com 09 Jan 2008: ps-print-buffer-with-faces hangs
+If no printer is connected to the printer port that Emacs is printing
+to, I/O to that port hangs in the system calls. Emacs should avoid
+defaulting to a printer port that is not in use.
+
 * BUGS WAITING FOR MORE USER INPUT
 
 ** raman@users.sf.net, sep 7: Emacs 23.0.50: Segfaults in alloc.c (batch process)
--- a/admin/make-tarball.txt	Tue Jan 22 15:44:14 2008 +0000
+++ b/admin/make-tarball.txt	Tue Jan 22 23:53:46 2008 +0000
@@ -73,9 +73,9 @@
     ftp://alpha.gnu.org/gnu/emacs/pretest/ for a pretest, at
     ftp://ftp.gnu.org/gnu/emacs/ for a release.
 
-14. For a pretest, let Richard Stallman <rms@gnu.org> know about the new pretest and
-    tell him to announce it using the announcement you prepared.  Remind
-    him to set a Reply-to header to <emacs-pretest-bug@gnu.org>.
+14. For a pretest, let Richard Stallman <rms@gnu.org> know about the new
+    pretest and tell him to announce it using the announcement you prepared.
+    Remind him to set a Reply-to header to <emacs-pretest-bug@gnu.org>.
 
 15. Shortly before the release, cut the branch with the following commands:
 
--- a/config.guess	Tue Jan 22 15:44:14 2008 +0000
+++ b/config.guess	Tue Jan 22 23:53:46 2008 +0000
@@ -1,10 +1,10 @@
 #! /bin/sh
 # Attempt to guess a canonical system name.
-#   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
-#                 2002, 2003, 2004, 2005, 2006, 2007
-#                 Free Software Foundation, Inc.
+#   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
+#   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+#   Free Software Foundation, Inc.
 
-timestamp='2007-02-26'
+timestamp='2008-01-08'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -56,8 +56,8 @@
 GNU config.guess ($timestamp)
 
 Originally written by Per Bothner.
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
-Free Software Foundation, Inc.
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
+2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This is free software; see the source for copying conditions.  There is NO
 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -330,7 +330,7 @@
     sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
 	echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
 	exit ;;
-    i86pc:SunOS:5.*:*)
+    i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
 	echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
 	exit ;;
     sun4*:SunOS:6*:*)
@@ -532,7 +532,7 @@
 		echo rs6000-ibm-aix3.2
 	fi
 	exit ;;
-    *:AIX:*:[45])
+    *:AIX:*:[456])
 	IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
 	if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
 		IBM_ARCH=rs6000
@@ -791,12 +791,18 @@
     i*:PW*:*)
 	echo ${UNAME_MACHINE}-pc-pw32
 	exit ;;
-    x86:Interix*:[3456]*)
-	echo i586-pc-interix${UNAME_RELEASE}
-	exit ;;
-    EM64T:Interix*:[3456]* | authenticamd:Interix*:[3456]*)
-	echo x86_64-unknown-interix${UNAME_RELEASE}
-	exit ;;
+    *:Interix*:[3456]*)
+    	case ${UNAME_MACHINE} in
+	    x86)
+		echo i586-pc-interix${UNAME_RELEASE}
+		exit ;;
+	    EM64T | authenticamd)
+		echo x86_64-unknown-interix${UNAME_RELEASE}
+		exit ;;
+	    IA64)
+		echo ia64-unknown-interix${UNAME_RELEASE}
+		exit ;;
+	esac ;;
     [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
 	echo i${UNAME_MACHINE}-pc-mks
 	exit ;;
@@ -830,7 +836,14 @@
 	echo ${UNAME_MACHINE}-pc-minix
 	exit ;;
     arm*:Linux:*:*)
-	echo ${UNAME_MACHINE}-unknown-linux-gnu
+	eval $set_cc_for_build
+	if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
+	    | grep -q __ARM_EABI__
+	then
+	    echo ${UNAME_MACHINE}-unknown-linux-gnu
+	else
+	    echo ${UNAME_MACHINE}-unknown-linux-gnueabi
+	fi
 	exit ;;
     avr32*:Linux:*:*)
 	echo ${UNAME_MACHINE}-unknown-linux-gnu
@@ -951,8 +964,8 @@
     x86_64:Linux:*:*)
 	echo x86_64-unknown-linux-gnu
 	exit ;;
-    xtensa:Linux:*:*)
-    	echo xtensa-unknown-linux-gnu
+    xtensa*:Linux:*:*)
+    	echo ${UNAME_MACHINE}-unknown-linux-gnu
 	exit ;;
     i*86:Linux:*:*)
 	# The BFD linker knows what the default object file format is, so
--- a/config.sub	Tue Jan 22 15:44:14 2008 +0000
+++ b/config.sub	Tue Jan 22 23:53:46 2008 +0000
@@ -1,10 +1,10 @@
 #! /bin/sh
 # Configuration validation subroutine script.
-#   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
-#                 2002, 2003, 2004, 2005, 2006, 2007
-#                 Free Software Foundation, Inc.
+#   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
+#   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+#   Free Software Foundation, Inc.
 
-timestamp='2007-02-26'
+timestamp='2008-01-16'
 
 # This file is (in principle) common to ALL GNU software.
 # The presence of a machine in this file suggests that SOME GNU software
@@ -72,8 +72,8 @@
 version="\
 GNU config.sub ($timestamp)
 
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
-Free Software Foundation, Inc.
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
+2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This is free software; see the source for copying conditions.  There is NO
 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -369,10 +369,14 @@
 	| v850-* | v850e-* | vax-* \
 	| we32k-* \
 	| x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
-	| xstormy16-* | xtensa-* \
+	| xstormy16-* | xtensa*-* \
 	| ymp-* \
 	| z8k-*)
 		;;
+	# Recognize the basic CPU types without company name, with glob match.
+	xtensa*)
+		basic_machine=$basic_machine-unknown
+		;;
 	# Recognize the various machine names and aliases which stand
 	# for a CPU type and a company and sometimes even an OS.
 	386bsd)
@@ -443,6 +447,14 @@
 		basic_machine=ns32k-sequent
 		os=-dynix
 		;;
+	blackfin)
+		basic_machine=bfin-unknown
+		os=-linux
+		;;
+	blackfin-*)
+		basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
+		os=-linux
+		;;
 	c90)
 		basic_machine=c90-cray
 		os=-unicos
@@ -475,8 +487,8 @@
 		basic_machine=craynv-cray
 		os=-unicosmp
 		;;
-	cr16c)
-		basic_machine=cr16c-unknown
+	cr16)
+		basic_machine=cr16-unknown
 		os=-elf
 		;;
 	crds | unos)
@@ -668,6 +680,14 @@
 		basic_machine=m68k-isi
 		os=-sysv
 		;;
+	m68knommu)
+		basic_machine=m68k-unknown
+		os=-linux
+		;;
+	m68knommu-*)
+		basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`
+		os=-linux
+		;;
 	m88k-omron*)
 		basic_machine=m88k-omron
 		;;
@@ -683,6 +703,10 @@
 		basic_machine=i386-pc
 		os=-mingw32
 		;;
+	mingw32ce)
+		basic_machine=arm-unknown
+		os=-mingw32ce
+		;;
 	miniframe)
 		basic_machine=m68000-convergent
 		;;
@@ -809,6 +833,14 @@
 		basic_machine=i860-intel
 		os=-osf
 		;;
+	parisc)
+		basic_machine=hppa-unknown
+		os=-linux
+		;;
+	parisc-*)
+		basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`
+		os=-linux
+		;;
 	pbd)
 		basic_machine=sparc-tti
 		;;
@@ -1017,6 +1049,10 @@
 		basic_machine=tic6x-unknown
 		os=-coff
 		;;
+	tile*)
+		basic_machine=tile-unknown
+		os=-linux-gnu
+		;;
 	tx39)
 		basic_machine=mipstx39-unknown
 		;;
--- a/doc/emacs/abbrevs.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/abbrevs.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, 2003,
-@c   2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Abbrevs
 @chapter Abbrevs
--- a/doc/emacs/ack.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/ack.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1994, 1995, 1996, 1997, 1999, 2000, 2001, 2002, 2003,
-@c   2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @node Acknowledgments, Screen, Concept Index, Top
--- a/doc/emacs/anti.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/anti.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 
 @node Antinews, Mac OS, X Resources, Top
--- a/doc/emacs/arevert-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/arevert-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in emacs-xtra.texi (when producing the
--- a/doc/emacs/basic.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/basic.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Basic, Minibuffer, Exiting, Top
 @chapter Basic Editing Commands
--- a/doc/emacs/buffers.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/buffers.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Buffers, Windows, Files, Top
 @chapter Using Multiple Buffers
--- a/doc/emacs/building.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/building.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Building, Maintaining, Programs, Top
 @chapter Compiling and Testing Programs
--- a/doc/emacs/cal-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/cal-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in emacs-xtra.texi (when producing the
--- a/doc/emacs/calendar.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/calendar.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Calendar/Diary, Gnus, Dired, Top
 @chapter The Calendar and the Diary
--- a/doc/emacs/cmdargs.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/cmdargs.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Emacs Invocation, X Resources, GNU Free Documentation License, Top
 @appendix Command Line Arguments for Emacs Invocation
--- a/doc/emacs/commands.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/commands.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @iftex
 @chapter Characters, Keys and Commands
--- a/doc/emacs/custom.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/custom.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Customization, Quitting, Amusements, Top
 @chapter Customization
--- a/doc/emacs/dired-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/dired-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in emacs-xtra.texi (when producing the
--- a/doc/emacs/dired.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/dired.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Dired, Calendar/Diary, Rmail, Top
 @chapter Dired, the Directory Editor
--- a/doc/emacs/display.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/display.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Display, Search, Registers, Top
 @chapter Controlling the Display
--- a/doc/emacs/emacs-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/emacs-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -10,7 +10,7 @@
 @copying
 This manual describes specialized features of Emacs.
 
-Copyright @copyright{} 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+Copyright @copyright{} 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/emacs/emacs.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/emacs.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -12,8 +12,8 @@
 updated for Emacs version @value{EMACSVER}.
 
 Copyright @copyright{} 1985, 1986, 1987, 1993, 1994, 1995, 1996, 1997,
-1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software
-Foundation, Inc.
+1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/emacs/emerge-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/emerge-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in emacs-xtra.texi (when producing the
--- a/doc/emacs/entering.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/entering.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 2001, 2002, 2003,
-@c   2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+@c   2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Entering Emacs, Exiting, Text Characters, Top
 @chapter Entering and Exiting Emacs
--- a/doc/emacs/files.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/files.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000,
-@c   2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Files, Buffers, Keyboard Macros, Top
 @chapter File Handling
--- a/doc/emacs/fixit.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/fixit.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Fixit, Keyboard Macros, Search, Top
 @chapter Commands for Fixing Typos
--- a/doc/emacs/fortran-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/fortran-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in emacs-xtra.texi (when producing the
--- a/doc/emacs/frames.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/frames.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000,
-@c   2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Frames, International, Windows, Top
 @chapter Frames and Graphical Displays
--- a/doc/emacs/glossary.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/glossary.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Glossary, Key Index, Intro, Top
 @unnumbered Glossary
--- a/doc/emacs/gnu.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/gnu.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,13 +1,13 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1995, 2001, 2002, 2003, 2004,
-@c   2005, 2006, 2007  Free Software Foundation, Inc.
+@c   2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 @ifclear justgnu
 @node Manifesto,, Microsoft Windows, Top
 @unnumbered The GNU Manifesto
 @end ifclear
 @ifset justgnu
 Copyright @copyright{} 1985, 1993, 2001, 2002, 2003, 2004,
-2005, 2006, 2007  Free Software Foundation, Inc.
+2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.2 or
--- a/doc/emacs/help.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/help.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Help, Mark, M-x, Top
 @chapter Help
--- a/doc/emacs/indent.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/indent.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Indentation, Text, Major Modes, Top
 @chapter Indentation
--- a/doc/emacs/killing.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/killing.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 
 @node Killing, Yanking, Mark, Top
--- a/doc/emacs/kmacro.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/kmacro.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Keyboard Macros, Files, Fixit, Top
 @chapter Keyboard Macros
--- a/doc/emacs/m-x.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/m-x.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node M-x, Help, Minibuffer, Top
 @chapter Running Commands by Name
--- a/doc/emacs/macos.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/macos.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 2000, 2001, 2002, 2003, 2004,
-@c   2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Mac OS, Microsoft Windows, Antinews, Top
 @appendix Emacs and Mac OS
--- a/doc/emacs/maintaining.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/maintaining.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000,
-@c   2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Maintaining, Abbrevs, Building, Top
 @chapter Maintaining Large Programs
--- a/doc/emacs/major.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/major.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Major Modes, Indentation, International, Top
 @chapter Major Modes
--- a/doc/emacs/mark.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/mark.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Mark, Killing, Help, Top
 @chapter The Mark and the Region
--- a/doc/emacs/mini.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/mini.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Minibuffer, M-x, Basic, Top
 @chapter The Minibuffer
--- a/doc/emacs/misc.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/misc.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @iftex
 @chapter Miscellaneous Commands
--- a/doc/emacs/msdog-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/msdog-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in emacs-xtra.texi (when producing the
--- a/doc/emacs/msdog.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/msdog.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Microsoft Windows, Manifesto, Mac OS, Top
 @appendix Emacs and Microsoft Windows/MS-DOS
--- a/doc/emacs/mule.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/mule.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1997, 1999, 2000, 2001, 2002, 2003, 2004,
-@c   2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node International, Major Modes, Frames, Top
 @chapter International Character Set Support
--- a/doc/emacs/picture-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/picture-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in emacs-xtra.texi (when producing the
--- a/doc/emacs/programs.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/programs.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000,
-@c   2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Programs, Building, Text, Top
 @chapter Editing Programs
--- a/doc/emacs/regs.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/regs.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Registers, Display, CUA Bindings, Top
 @chapter Registers
--- a/doc/emacs/rmail.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/rmail.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Rmail, Dired, Sending Mail, Top
 @chapter Reading Mail with Rmail
--- a/doc/emacs/screen.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/screen.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Screen, User Input, Acknowledgments, Top
 @chapter The Organization of the Screen
--- a/doc/emacs/search.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/search.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Search, Fixit, Display, Top
 @chapter Searching and Replacement
--- a/doc/emacs/sending.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/sending.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Sending Mail
 @chapter Sending Mail
--- a/doc/emacs/text.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/text.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Text, Programs, Indentation, Top
 @chapter Commands for Human Languages
--- a/doc/emacs/trouble.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/trouble.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002,
-@c   2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @iftex
 @chapter Dealing with Common Problems
--- a/doc/emacs/vc-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/vc-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included in emacs-xtra.texi when producing the printed
--- a/doc/emacs/vc1-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/vc1-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in vc-xtra.texi (when producing the
--- a/doc/emacs/vc2-xtra.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/vc2-xtra.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,5 +1,5 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @c
 @c This file is included either in vc-xtra.texi (when producing the
--- a/doc/emacs/windows.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/windows.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
-@c   2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node Windows, Frames, Buffers, Top
 @chapter Multiple Windows
--- a/doc/emacs/xresources.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/emacs/xresources.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
 @c Copyright (C) 1987, 1993, 1994, 1995, 1997, 2001, 2002, 2003,
-@c   2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c   2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @node X Resources, Antinews, Emacs Invocation, Top
 @appendix X Options and Resources
--- a/doc/lispref/ChangeLog	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/lispref/ChangeLog	Tue Jan 22 23:53:46 2008 +0000
@@ -1,3 +1,7 @@
+2008-01-19  Martin Rudalics  <rudalics@gmx.at>
+
+	* buffers.texi (Buffer Modification): Fix typo.
+
 2008-01-06  Dan Nicolaescu  <dann@ics.uci.edu>
 
 	* os.texi (System Environment): Remove references to OSes that are
--- a/doc/lispref/buffers.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/lispref/buffers.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -584,7 +584,7 @@
 This function returns @var{buffer}'s character-change modification-count.
 Changes to text properties leave this counter unchanged; however, each
 time text is inserted or removed from the buffer, the counter is reset
-to the value that would be returned @code{buffer-modified-tick}.
+to the value that would be returned by @code{buffer-modified-tick}.
 By comparing the values returned by two @code{buffer-chars-modified-tick}
 calls, you can tell whether a character change occurred in that buffer
 in between the calls.  If @var{buffer} is @code{nil} (or omitted), the
@@ -783,7 +783,7 @@
 to the end when they are buried (see @code{bury-buffer}, below).
 There are no functions available to the Lisp programmer which directly
 manipulate the buffer list.
-  
+
   In addition to the fundamental Emacs buffer list, each frame has its
 own version of the buffer list, in which the buffers that have been
 selected in that frame come first, starting with the buffers most
--- a/doc/misc/Makefile.in	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/Makefile.in	Tue Jan 22 23:53:46 2008 +0000
@@ -1,7 +1,7 @@
 #### Makefile for documentation other than the Emacs manual.
 
 # Copyright (C) 1994, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
-#   2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+#   2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 # This file is part of GNU Emacs.
 
--- a/doc/misc/ada-mode.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/ada-mode.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -4,7 +4,7 @@
 
 @copying
 Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004,
-2005, 2006, 2007  Free Software Foundation, Inc.
+2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/autotype.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/autotype.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,7 +1,7 @@
 \input texinfo
 @c This is an annex of the Emacs manual.
 @c Copyright (C) 1994, 1995, 2001, 2002, 2003, 2004,
-@c   2005, 2006, 2007  Free Software Foundation, Inc.
+@c   2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 @c Author: Daniel.Pfeiffer@Informatik.START.dbp.de, fax (+49 69) 7588-2389
 @setfilename ../../info/autotype
 @c @node Autotypist, Picture, Abbrevs, Top
@@ -13,7 +13,7 @@
 
 @copying
 Copyright @copyright{} 1994, 1995, 1999, 2001, 2002, 2003, 2004,
-2005, 2006, 2007  Free Software Foundation, Inc.
+2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/calc.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/calc.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -84,7 +84,7 @@
 This file documents Calc, the GNU Emacs calculator.
 
 Copyright @copyright{} 1990, 1991, 2001, 2002, 2003, 2004,
-2005, 2006, 2007 Free Software Foundation, Inc.
+2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
@@ -119,7 +119,7 @@
 
 @vskip 0pt plus 1filll
 Copyright @copyright{} 1990, 1991, 2001, 2002, 2003, 2004,
-   2005, 2006, 2007 Free Software Foundation, Inc.
+   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 @insertcopying
 @end titlepage
 
--- a/doc/misc/cc-mode.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/cc-mode.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -160,7 +160,7 @@
 This manual is for CC Mode in Emacs.
 
 Copyright @copyright{} 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-2003, 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/cl.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/cl.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -5,7 +5,7 @@
 @copying
 This file documents the GNU Emacs Common Lisp emulation package.
 
-Copyright @copyright{} 1993, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+Copyright @copyright{} 1993, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 Free Software Foundation, Inc.
 
 @quotation
--- a/doc/misc/dired-x.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/dired-x.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -26,7 +26,7 @@
 
 @copying
 Copyright @copyright{} 1994, 1995, 1999, 2001, 2002, 2003, 2004,
-2005, 2006, 2007  Free Software Foundation, Inc.
+2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/ebrowse.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/ebrowse.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -11,7 +11,7 @@
 This file documents Ebrowse, a C++ class browser for GNU Emacs.
 
 Copyright @copyright{} 2000, 2001, 2002, 2003, 2004,
-2005, 2006, 2007  Free Software Foundation, Inc.
+2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/ediff.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/ediff.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -26,7 +26,7 @@
 and patch utilities.
 
 Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/emacs-mime.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/emacs-mime.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -10,7 +10,7 @@
 This file documents the Emacs MIME interface functionality.
 
 Copyright @copyright{} 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
-2006, 2007 Free Software Foundation, Inc.
+2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/erc.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/erc.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -14,7 +14,7 @@
 @copying
 This manual is for ERC version 5.2.
 
-Copyright @copyright{} 2005, 2006, 2007 Free Software Foundation, Inc.
+Copyright @copyright{} 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/eshell.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/eshell.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -9,7 +9,7 @@
 This manual is for Eshell, the Emacs shell.
 
 Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004,
-2005, 2006, 2007 Free Software Foundation, Inc.
+2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/eudc.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/eudc.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -12,7 +12,7 @@
 directory servers using various protocols such as LDAP or the CCSO white
 pages directory system (PH/QI)
 
-Copyright @copyright{} 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+Copyright @copyright{} 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 Free Software Foundation, Inc.
 
 @quotation
--- a/doc/misc/faq.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/faq.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -14,7 +14,7 @@
 @c appreciate a notice if you do).
 
 @copying
-Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006, 2007
+Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 Free Software Foundation, Inc.@*
 Copyright 1994,1995,1996,1997,1998,1999,2000 Reuven M. Lerner@*
 Copyright 1992,1993 Steven Byrnes@*
--- a/doc/misc/flymake.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/flymake.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -11,7 +11,7 @@
 This manual is for GNU Flymake (version @value{VERSION}, @value{UPDATED}),
 which is a universal on-the-fly syntax checker for GNU Emacs.
 
-Copyright @copyright{} 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+Copyright @copyright{} 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/forms.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/forms.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -19,7 +19,7 @@
 This file documents Forms mode, a form-editing major mode for GNU Emacs.
 
 Copyright @copyright{} 1989, 1997, 2001, 2002, 2003, 2004,
-2005, 2006, 2007 Free Software Foundation, Inc.
+2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/gnus-faq.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/gnus-faq.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,7 +1,8 @@
 @c \input texinfo @c -*-texinfo-*-
 @c Uncomment 1st line before texing this file alone.
 @c %**start of header
-@c Copyright (C) 1995, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+@c Copyright (C) 1995, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
+@c   2008 Free Software Foundation, Inc.
 @c
 @c Do not modify this file, it was generated from gnus-faq.xml, available from
 @c <URL:http://my.gnus.org/FAQ/>.
--- a/doc/misc/idlwave.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/idlwave.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -27,7 +27,7 @@
 @value{VERSION}
 
 Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, 
-          2006, 2007 Free Software Foundation, Inc.
+          2006, 2007, 2008 Free Software Foundation, Inc.
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.2 or
@@ -58,7 +58,7 @@
 IDLWAVE version @value{VERSION}, @value{DATE}.
 @sp 2
 Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, 
-          2006, 2007 Free Software Foundation, Inc.
+          2006, 2007, 2008 Free Software Foundation, Inc.
 @sp 2
 @cindex Copyright, of IDLWAVE
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/info.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/info.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -15,7 +15,7 @@
 documentation system.
 
 Copyright @copyright{} 1989, 1992, 1996, 1997, 1998, 1999, 2000, 2001,
-2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/makefile.w32-in	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/makefile.w32-in	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,6 @@
 #### -*- Makefile -*- for documentation other than the Emacs manual.
 
-# Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+# Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 # This file is part of GNU Emacs.
 
--- a/doc/misc/mh-e.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/mh-e.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -24,7 +24,7 @@
 This is version @value{VERSION}@value{EDITION} of @cite{The MH-E
 Manual}, last updated @value{UPDATED}.
 
-Copyright @copyright{} 1995, 2001, 2002, 2003, 2005, 2006, 2007 Free
+Copyright @copyright{} 1995, 2001, 2002, 2003, 2005, 2006, 2007, 2008 Free
 Software Foundation, Inc.
 
 @quotation
--- a/doc/misc/newsticker.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/newsticker.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -13,7 +13,7 @@
 This manual is for Newsticker (version @value{VERSION}, @value{UPDATED}).
 
 @noindent
-Copyright @copyright{} 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+Copyright @copyright{} 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/pcl-cvs.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/pcl-cvs.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -7,8 +7,8 @@
 
 @copying
 Copyright @copyright{} 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007  Free Software
-Foundation, Inc.
+1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/pgg.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/pgg.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -8,8 +8,8 @@
 @copying
 This file describes PGG, an Emacs interface to various PGP implementations.
 
-Copyright @copyright{} 2001, 2003, 2004, 2005, 2006, 2007  Free Software
-Foundation, Inc.
+Copyright @copyright{} 2001, 2003, 2004, 2005, 2006, 2007, 2008
+Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/rcirc.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/rcirc.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -5,7 +5,7 @@
 @c %**end of header
 
 @copying
-Copyright @copyright{} 2006, 2007 Free Software Foundation, Inc.
+Copyright @copyright{} 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/reftex.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/reftex.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -28,7 +28,7 @@
 @b{Ref@TeX{}} @value{VERSION}
 
 Copyright @copyright{} 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-2005, 2006, 2007  Free Software Foundation, Inc.
+2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/sc.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/sc.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -16,7 +16,7 @@
 subsystems.
 
 Copyright @copyright{} 1993, 2001, 2002, 2003, 2004,
-2005, 2006, 2007 Free Software Foundation, Inc.
+2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/ses.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/ses.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -11,7 +11,7 @@
 @copying
 This file documents SES: the Simple Emacs Spreadsheet.
 
-Copyright @copyright{} 2002, 2003, 2004, 2005, 2006, 2007
+Copyright @copyright{} 2002, 2003, 2004, 2005, 2006, 2007, 2008
 Free Software Foundation, Inc.
 
 @quotation
--- a/doc/misc/sieve.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/sieve.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -9,7 +9,7 @@
 @copying
 This file documents the Emacs Sieve package, for server-side mail filtering.
 
-Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006, 2007
+Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 Free Software Foundation, Inc.
 
 @quotation
--- a/doc/misc/smtpmail.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/smtpmail.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -3,7 +3,8 @@
 @settitle Emacs SMTP Library
 @syncodeindex vr fn
 @copying
-Copyright @copyright{} 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+Copyright @copyright{} 2003, 2004, 2005, 2006, 2007, 2008
+Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/speedbar.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/speedbar.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -6,7 +6,7 @@
 
 @copying
 Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
-2007  Free Software Foundation, Inc.
+2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/texinfo.tex	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/texinfo.tex	Tue Jan 22 23:53:46 2008 +0000
@@ -7,7 +7,7 @@
 %
 % Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
 % 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
-% 2007 Free Software Foundation, Inc.
+% 2007, 2008 Free Software Foundation, Inc.
 %
 % This texinfo.tex file is free software; you can redistribute it and/or
 % modify it under the terms of the GNU General Public License as
--- a/doc/misc/trampver.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/trampver.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -1,6 +1,11 @@
 @c -*-texinfo-*-
 @c texi/trampver.texi.  Generated from trampver.texi.in by configure.
 
+@c This is part of the Emacs manual.
+@c Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008
+@c   Free Software Foundation, Inc.
+@c See file emacs.texi for copying conditions.
+
 @c In the Tramp CVS, the version number is auto-frobbed from
 @c configure.ac, so you should edit that file and run
 @c "autoconf && ./configure" to change the version number.
--- a/doc/misc/url.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/url.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -22,7 +22,7 @@
 This file documents the URL loading package.
 
 Copyright @copyright{} 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2002,
-2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.2 or
@@ -50,7 +50,7 @@
 @page
 @vskip 0pt plus 1filll
 Copyright @copyright{} 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2002,
-2003, 2004, 2005, 2006, 2007  Free Software Foundation, Inc.
+2003, 2004, 2005, 2006, 2007, 2008  Free Software Foundation, Inc.
 
 Permission is granted to copy, distribute and/or modify this document
 under the terms of the GNU Free Documentation License, Version 1.2 or
--- a/doc/misc/vip.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/vip.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -5,7 +5,7 @@
 
 @copying
 Copyright @copyright{} 1987, 2001, 2002, 2003, 2004,
-2005, 2006, 2007 Free Software Foundation, Inc.
+2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/viper.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/viper.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -8,7 +8,7 @@
 
 @copying
 Copyright @copyright{} 1995, 1996, 1997, 2001, 2002, 2003, 2004,
-2005, 2006, 2007 Free Software Foundation, Inc.
+2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/widget.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/widget.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -11,7 +11,7 @@
 
 @copying
 Copyright @copyright{} 2000, 2001, 2002, 2003, 2004, 2005,
-2006, 2007  Free Software Foundation, Inc.
+2006, 2007, 2008  Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/doc/misc/woman.texi	Tue Jan 22 15:44:14 2008 +0000
+++ b/doc/misc/woman.texi	Tue Jan 22 23:53:46 2008 +0000
@@ -18,7 +18,7 @@
 (without) man'.
 
 Copyright @copyright{} 2001, 2002, 2003, 2004,
-2005, 2006, 2007 Free Software Foundation, Inc.
+2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 @quotation
 Permission is granted to copy, distribute and/or modify this document
--- a/etc/NEWS.22	Tue Jan 22 15:44:14 2008 +0000
+++ b/etc/NEWS.22	Tue Jan 22 23:53:46 2008 +0000
@@ -112,6 +112,13 @@
 
 *** VC has some support for Git.
 
+* Incompatible Lisp Changes in Emacs 22.2
+
+** shell.el no longer defines the aliases `dirtrack-toggle' and
+`dirtrack-mode' for `shell-dirtrack-mode'.  These names were removed
+because they clash with commands provided by dirtrack.el.  Use
+`shell-dirtrack-mode' instead.
+
 * Lisp Changes in Emacs 22.2.
 
 ** Frame-local variables are deprecated and are slated for removal.
--- a/etc/images/mail/README	Tue Jan 22 15:44:14 2008 +0000
+++ b/etc/images/mail/README	Tue Jan 22 23:53:46 2008 +0000
@@ -1,7 +1,7 @@
 COPYRIGHT AND LICENSE INFORMATION FOR IMAGE FILES
 
 The following icons are from GNOME 2.x. They are not part of Emacs,
-but distributed and used by Emacs.  They are licensed under the
+but are distributed and used by Emacs.  They are licensed under the
 GNU General Public License version 2 or later.  See the source of the
 gnome-icons-theme package for more information.
 
--- a/leim/ChangeLog	Tue Jan 22 15:44:14 2008 +0000
+++ b/leim/ChangeLog	Tue Jan 22 23:53:46 2008 +0000
@@ -1,3 +1,8 @@
+2008-01-14  Aidan Kehoe  <kehoea@parhasard.net>  (tiny change)
+
+        * quail/latin-ltx.el ("TeX"): Correct the mappings for \v{k} and
+	\vk.
+
 2008-01-06  Dan Nicolaescu  <dann@ics.uci.edu>
 
 	* makefile.w32-in:
--- a/leim/quail/latin-ltx.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/leim/quail/latin-ltx.el	Tue Jan 22 23:53:46 2008 +0000
@@ -263,7 +263,7 @@
  ("\\v{G}" ?Ǧ) ("\\vG" ?Ǧ)
  ("\\v{g}" ?ǧ) ("\\vg" ?ǧ)
  ("\\v{K}" ?Ǩ) ("\\vK" ?Ǩ)
- ("\\v{k}" ?k) ("\\vk" ?k)
+ ("\\v{k}" ?Ç©) ("\\vk" ?Ç©)
 
  ("\\v{\\j}" ?Ç°) ("\\vj" ?Ç°)
  ("\\'{G}" ?Ç´) ("\\'G" ?Ç´)
--- a/lisp/ChangeLog	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/ChangeLog	Tue Jan 22 23:53:46 2008 +0000
@@ -1,3 +1,187 @@
+2008-01-19  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* progmodes/sh-script.el (sh-basic-offset):
+	* progmodes/cc-vars.el (c-syntactic-indentation)
+	(c-syntactic-indentation-in-macros): Mark as safe.
+
+2008-01-18  Richard Stallman  <rms@gnu.org>
+
+	* icomplete.el (icomplete-get-keys):
+	Look up KEYS using all maps in proper buffer.
+
+2008-01-17  Vinicius Jose Latorre  <viniciusjl@ig.com.br>
+	    Miles Bader  <miles@gnu.org>
+
+	* blank-mode.el: New file.  Minor mode to visualise TAB,
+	(HARD) SPACE, NEWLINE.  Miles Bader <miles@gnu.org> wrote the original
+	code for handling display table (via visws.el package), his code was
+	modified, but the main idea was kept.
+
+2008-01-16  Alan Mackenzie  <acm@muc.de>
+
+	* progmodes/cc-vars.el (c-constant-symbol): Put this defun inside
+	an eval-and-compile, so as to permit byte-compiling (e.g. in
+	bootstrap).
+
+2008-01-16  Juanma Barranquero  <lekktu@gmail.com>
+
+	* frame.el (display-mm-height, display-mm-width):
+	* whitespace.el (whitespace-check-leading-whitespace)
+	(whitespace-check-trailing-whitespace)
+	(whitespace-check-spacetab-whitespace)
+	(whitespace-check-indent-whitespace)
+	(whitespace-check-ateol-whitespace):
+	* progmodes/ada-xref.el (ada-convert-file-name): Fix typo in docstring.
+
+2008-01-15  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* vc-arch.el (vc-arch-delete-rej-if-obsolete): Remove the
+	after-save-hook so that it is not called multiple times.
+
+	* vc-svn.el (vc-svn-resolve-when-done): Likewise.
+
+2008-01-12  Eli Zaretskii  <eliz@gnu.org>
+
+	* view.el (view-file-other-window, view-file-other-frame): Don't
+	kill the buffer if it is modified.  Doc fixes.
+	(kill-buffer-if-not-modified): New function.
+	(view-file): Don't kill the buffer if it is modified.
+
+	* progmodes/ebrowse.el (ebrowse-view-file-other-window): Delete
+	function.
+	(ebrowse-view/find-file-and-search-pattern): Call
+	view-file-other-window instead of ebrowse-view-file-other-window.
+	(ebrowse-view-file-other-frame): Don't call
+	current-window-configuration.  Fix second argument in the call to
+	view-mode-enter.  Doc fix.
+
+2008-01-11  Richard Stallman  <rms@gnu.org>
+
+	* subr.el (atomic-change-group): Prevent undo list truncation.
+
+2008-01-10  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* files.el (safe-local-eval-forms): Mark
+	(add-hook 'write-file-hooks 'time-stamp) as safe.
+
+2008-01-10  Nick Roberts  <nickrob@snap.net.nz>
+
+	* comint.el (comint-insert-input): Set point first.
+
+	* progmodes/gdb-ui.el (gdb-dequeue-input): Make doubly sure
+	session doesn't hang because gdb-pending-triggers is non-nil.
+	(gdb-frame-handler): Use buffer-file-name instead of
+	buffer-name in case of duplicate file names.
+
+2008-01-10  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* progmodes/verilog-mode.el (verilog-mode-map): Don't bind C-M-a,
+	C-M-e and C-M-h for emacs, they work by default.
+	(verilog-emacs-features): Remove.
+	(verilog-setup-dual-comments, verilog-populate-syntax-table):
+	Remove.  Move syntax table initialization ...
+	(verilog-mode-syntax-table): ... here.
+	(verilog-mode): Don't initialize the syntax table here.
+	(verilog-mark-defun): Only do something useful for XEmacs, emacs
+	does not need it.
+
+2008-01-09  Wilson Snyder  <wsnyder@wsnyder.org>
+
+	* progmodes/verilog-mode.el (verilog-booleanp): New function for
+	backward compatibility.  Replace all uses of booleanp with
+	verilog-booleanp.
+
+2008-01-09  Dan Nicolaescu  <dann@ics.uci.edu>
+
+	* vc-hg.el (vc-hg-diff): Don't pass an empty string.
+
+2008-01-09  Wilson Snyder  <wsnyder@wsnyder.org>
+
+	* progmodes/verilog-mode.el (top-level): Fix spacing.
+	(verilog-mode-version, verilog-mode-release-date): Update version
+	number.
+	(verilog-mode-release-emacs): New variable.
+	(compile-command, reporter-prompt-for-summary-p): Define for byte
+	compiler.
+	(verilog-startup-message-lines)
+	(verilog-startup-message-displayed)
+	(verilog-display-startup-message): Remove.
+	(verilog-highlight-p1800-keywords): Improve docstring.
+	(sigs-in, sigs-out, got-sig, got-rvalue, uses-delayed)
+	(vector-skip-list): Only defvar at compile time.
+	(verilog-highlight-translate-off, verilog-indent-level)
+	(verilog-indent-level-module, verilog-indent-level-declaration)
+	(verilog-indent-declaration-macros, verilog-indent-lists)
+	(verilog-indent-level-behavioral)
+	(verilog-indent-level-directive, verilog-cexp-indent)
+	(verilog-case-indent, verilog-auto-newline)
+	(verilog-auto-indent-on-newline, verilog-tab-always-indent)
+	(verilog-tab-to-comment, verilog-indent-begin-after-if)
+	(verilog-align-ifelse, verilog-minimum-comment-distance)
+	(verilog-auto-lineup, verilog-highlight-p1800-keywords)
+	(verilog-auto-endcomments, verilog-auto-read-includes)
+	(verilog-auto-star-expand, verilog-auto-star-save)
+	(verilog-library-flags, verilog-library-directories)
+	(verilog-library-files, verilog-library-extensions)
+	(verilog-active-low-regexp, verilog-auto-sense-include-inputs)
+	(verilog-auto-sense-defines-constant, verilog-auto-reset-widths)
+	(verilog-assignment-delay, verilog-auto-inst-vector)
+	(verilog-auto-inst-template-numbers)
+	(verilog-auto-input-ignore-regexp)
+	(verilog-auto-inout-ignore-regexp)
+	(verilog-auto-output-ignore-regexp)
+	(verilog-auto-unused-ignore-regexp, verilog-typedef-regexp): Add
+	safe-local-variable properties.
+	(verilog-statement-menu, verilog-company)
+	(verilog-re-search-forward, verilog-re-search-backward)
+	(verilog-error-regexp-add, verilog-end-block-re)
+	(verilog-emacs-features, verilog-populate-syntax-table)
+	(verilog-setup-dual-comments, verilog-type-font-keywords)
+	(verilog-inside-comment-p, electric-verilog-backward-sexp)
+	(verilog-backward-sexp, verilog-forward-sexp)
+	(verilog-font-lock-init, verilog-mode)
+	(electric-verilog-terminate-line, electric-verilog-semi)
+	(electric-verilog-tab, verilog-insert-1, )
+	(verilog-insert-indices, verilog-generate-numbers)
+	(verilog-comment-region, verilog-label-be)
+	(verilog-beg-of-statement, verilog-in-case-region-p)
+	(verilog-in-struct-region-p, verilog-in-generate-region-p)
+	(verilog-in-fork-region-p, verilog-backward-case-item)
+	(verilog-set-auto-endcomments, verilog-get-expr)
+	(verilog-expand-vector-internal, verilog-surelint-off)
+	(verilog-batch-execute-func, verilog-calculate-indent)
+	(verilog-calc-1, verilog-calculate-indent-directive)
+	(verilog-leap-to-head, verilog-continued-line)
+	(verilog-backward-token, verilog-backward-syntactic-ws)
+	(verilog-forward-syntactic-ws, verilog-backward-ws&directives)
+	(verilog-forward-ws&directives, verilog-at-constraint-p)
+	(verilog-skip-backward-comments, verilog-indent-line-relative)
+	(verilog-do-indent, verilog-indent-comment)
+	(verilog-more-comment, verilog-pretty-declarations)
+	(verilog-pretty-expr, verilog-just-one-space)
+	(verilog-indent-declaration, verilog-get-completion-decl)
+	(verilog-goto-defun, verilog-showscopes, verilog-header)
+	(verilog-signals-combine-bus, verilog-read-decls)
+	(verilog-read-always-signals-recurse, verilog-read-instants)
+	(verilog-read-auto-template, verilog-set-define)
+	(verilog-read-defines, verilog-read-signals, verilog-getopt)
+	(verilog-is-number, verilog-expand-dirnames)
+	(verilog-modi-lookup, verilog-modi-cache-results)
+	(verilog-insert-one-definition, verilog-make-width-expression)
+	(verilog-delete-autos-lined, verilog-auto-save-check)
+	(verilog-auto-arg, verilog-auto-inst-port, verilog-auto-inst)
+	(verilog-auto-inst-param, verilog-auto-reg)
+	(verilog-auto-reg-input, verilog-auto-wire, )
+	(verilog-auto-output, verilog-auto-output-every)
+	(verilog-auto-input, verilog-auto-inout)
+	(verilog-auto-inout-module, verilog-auto-sense)
+	(verilog-auto-reset, verilog-auto-tieoff, verilog-auto-unused)
+	(verilog-auto-ascii-enum, verilog-auto)
+	(verilog-sk-define-signal, verilog-mode-mouse-map)
+	(verilog-load-file-at-mouse, verilog-load-file-at-point)
+	(verilog-library-files): Cleanup spacing of )'s they should not be
+	on unique lines.  Fix checkdoc warnings.
+
 2008-01-22  Glenn Morris  <rgm@gnu.org>
 
 	* progmodes/hideif.el (hide-ifdef-initially, hide-ifdef-read-only)
--- a/lisp/ChangeLog.12	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/ChangeLog.12	Tue Jan 22 23:53:46 2008 +0000
@@ -250,7 +250,7 @@
 2007-04-15  Roland Winkler  <Roland.Winkler@physik.uni-erlangen.de>
 
 	* textmodes/bibtex.el (bibtex-field-list): Use functionp.
-	(bibtex-make-field): Check that INIT is a string. Use functionp.
+	(bibtex-make-field): Check that INIT is a string.  Use functionp.
 
 2007-04-14  Glenn Morris  <rgm@gnu.org>
 
@@ -1214,7 +1214,7 @@
 	* progmodes/idlw-help.el (idlwave-do-context-help1): Don't visit
 	special help topics for keywords.
 	(idlwave-help-assistant-command): Include ".exe" for ms-dos
-	etc. Assistant command.
+	etc.  Assistant command.
 
 2007-03-08  Chong Yidong  <cyd@stupidchicken.com>
 
@@ -2133,7 +2133,7 @@
 	(newsticker--decode-iso8601-date): Bugfix for datestrings without
 	days.
 	(newsticker--buffer-do-insert-text): Fix.
-	(newsticker--buffer-insert-enclosure): Fix. length might be missing.
+	(newsticker--buffer-insert-enclosure): Fix.  Length might be missing.
 	(newsticker--buffer-make-item-completely-visible):
 	`switch-to-buffer' not necessary.
 
@@ -5365,7 +5365,7 @@
 	After 5.3, 5.4:
 	(cperl-facemenu-add-face-function): Add docs, fix U<>.
 	Copyright message updated.
-	(cperl-init-faces): Work around a bug in `font-lock'. May slow
+	(cperl-init-faces): Work around a bug in `font-lock'.  May slow
 			facification down a bit.
 		Misprint for my|our|local for old `font-lock'
 			"our" was not fontified same as "my|local".
@@ -5881,7 +5881,7 @@
 
 2006-09-26  Vinicius Jose Latorre  <viniciusjl@ig.com.br>
 
-	* progmodes/ebnf2ps.el: Doc fix. Implement arrow spacing and scaling.
+	* progmodes/ebnf2ps.el: Doc fix.  Implement arrow spacing and scaling.
 	(ebnf-version): New version 4.3.
 	(ebnf-arrow-extra-width, ebnf-arrow-scale): New options.
 	(ebnf-prologue): Adjust PostScript programming.
--- a/lisp/comint.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/comint.el	Tue Jan 22 23:53:46 2008 +0000
@@ -822,6 +822,7 @@
 If there is no previous input at point, run the command specified
 by the global keymap (usually `mouse-yank-at-point')."
   (interactive "e")
+  (mouse-set-point event)
   (let ((pos (posn-point (event-end event)))
 	field input)
     (with-selected-window (posn-window (event-end event))
--- a/lisp/files.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/files.el	Tue Jan 22 23:53:46 2008 +0000
@@ -2488,13 +2488,13 @@
   :group 'find-file
   :type  'alist)
 
-(defcustom safe-local-eval-forms nil
+(defcustom safe-local-eval-forms '((add-hook 'write-file-hooks 'time-stamp))
   "Expressions that are considered safe in an `eval:' local variable.
 Add expressions to this list if you want Emacs to evaluate them, when
 they appear in an `eval' local variable specification, without first
 asking you for confirmation."
   :group 'find-file
-  :version "22.1"
+  :version "22.2"
   :type '(repeat sexp))
 
 ;; Risky local variables:
--- a/lisp/frame.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/frame.el	Tue Jan 22 23:53:46 2008 +0000
@@ -1254,7 +1254,7 @@
 
 (defun display-mm-height (&optional display)
   "Return the height of DISPLAY's screen in millimeters.
-System values can be overriden by `display-mm-dimensions-alist'.
+System values can be overridden by `display-mm-dimensions-alist'.
 If the information is unavailable, value is nil."
   (and (memq (framep-on-display display) '(x w32 mac))
        (or (cddr (assoc (or display (frame-parameter nil 'display))
@@ -1264,7 +1264,7 @@
 
 (defun display-mm-width (&optional display)
   "Return the width of DISPLAY's screen in millimeters.
-System values can be overriden by `display-mm-dimensions-alist'.
+System values can be overridden by `display-mm-dimensions-alist'.
 If the information is unavailable, value is nil."
   (and (memq (framep-on-display display) '(x w32 mac))
        (or (cadr (assoc (or display (frame-parameter nil 'display))
--- a/lisp/icomplete.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/icomplete.el	Tue Jan 22 23:53:46 2008 +0000
@@ -147,8 +147,7 @@
     (save-excursion
       (let* ((sym (intern func-name))
 	     (buf (other-buffer nil t))
-	     (map (save-excursion (set-buffer buf) (current-local-map)))
-	     (keys (where-is-internal sym map)))
+	     (keys (with-current-buffer buf (where-is-internal sym))))
 	(if keys
 	    (concat "<"
 		    (mapconcat 'key-description
--- a/lisp/progmodes/ada-mode.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/progmodes/ada-mode.el	Tue Jan 22 23:53:46 2008 +0000
@@ -4955,11 +4955,11 @@
 ;; cursor at the correct position.
 ;; Standard Ada does not force any relation between unit names and file names,
 ;; so some of these functions can only be a good approximation. However, they
-;; are also overriden in `ada-xref'.el when we know that the user is using
+;; are also overridden in `ada-xref'.el when we know that the user is using
 ;; GNAT.
 ;; ---------------------------------------------------
 
-;; Overriden when we work with GNAT, to use gnatkrunch
+;; Overridden when we work with GNAT, to use gnatkrunch
 (defun ada-make-filename-from-adaname (adaname)
   "Determine the filename in which ADANAME is found.
 This matches the GNAT default naming convention, except for
--- a/lisp/progmodes/ada-xref.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/progmodes/ada-xref.el	Tue Jan 22 23:53:46 2008 +0000
@@ -617,7 +617,7 @@
 
 (defun ada-convert-file-name (name)
   "Convert from NAME to a name that can be used by the compilation commands.
-This is overriden on VMS to convert from VMS filenames to Unix filenames."
+This is overridden on VMS to convert from VMS filenames to Unix filenames."
   name)
 ;; FIXME: use convert-standard-filename instead
 
--- a/lisp/progmodes/cc-vars.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/progmodes/cc-vars.el	Tue Jan 22 23:53:46 2008 +0000
@@ -325,6 +325,7 @@
   :type 'boolean
   :group 'c)
 (make-variable-buffer-local 'c-syntactic-indentation)
+(put 'c-syntactic-indentation 'safe-local-variable 'booleanp)
 
 (defcustom c-syntactic-indentation-in-macros t
   "*Enable syntactic analysis inside macros.
@@ -343,6 +344,7 @@
 better with the \"do { ... } while \(0)\" trick)."
   :type 'boolean
   :group 'c)
+(put 'c-syntactic-indentation-in-macros 'safe-local-variable 'booleanp)
 
 (defcustom-c-stylevar c-comment-only-line-offset 0
   "*Extra offset for line which contains only the start of a comment.
--- a/lisp/progmodes/ebrowse.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/progmodes/ebrowse.el	Tue Jan 22 23:53:46 2008 +0000
@@ -1614,21 +1614,6 @@
     file-name))
 
 
-(defun ebrowse-view-file-other-window (file)
-  "View a file FILE in another window.
-This is a replacement for `view-file-other-window' which does not
-seem to work. It should be removed when `view.el' is fixed."
-  (interactive)
-  (let ((old-arrangement (current-window-configuration))
-	(had-a-buf (get-file-buffer file))
-	(buf-to-view (find-file-noselect file)))
-    (switch-to-buffer-other-window buf-to-view)
-    (view-mode-enter old-arrangement
-		     (and (not had-a-buf)
-			  (not (buffer-modified-p buf-to-view))
-			  'kill-buffer))))
-
-
 (defun ebrowse-view-exit-fn (buffer)
   "Function called when exiting View mode in BUFFER.
 Restore frame configuration active before viewing the file,
@@ -1649,10 +1634,9 @@
 
 (defun ebrowse-view-file-other-frame (file)
   "View a file FILE in another frame.
-The new frame is deleted when it is no longer used."
+The new frame is deleted when you quit viewing the file in that frame."
   (interactive)
   (let ((old-frame-configuration (current-frame-configuration))
-	(old-arrangement (current-window-configuration))
 	(had-a-buf (get-file-buffer file))
 	(buf-to-view (find-file-noselect file)))
     (switch-to-buffer-other-frame buf-to-view)
@@ -1663,8 +1647,8 @@
 	  (and (not had-a-buf)
 	       (not (buffer-modified-p buf-to-view))
 	       'kill-buffer))
-    (view-mode-enter old-arrangement 'ebrowse-view-exit-fn)))
-
+    (view-mode-enter (cons (selected-window) (cons (selected-window) t))
+		     'ebrowse-view-exit-fn)))
 
 (defun ebrowse-view/find-file-and-search-pattern
   (struc info file tags-file-name &optional view where)
@@ -1699,7 +1683,7 @@
 	   (setq view-mode-hook nil))
 	 (push 'ebrowse-find-pattern view-mode-hook)
 	 (case where
-	   (other-window (ebrowse-view-file-other-window file))
+	   (other-window (view-file-other-window file))
 	   (other-frame  (ebrowse-view-file-other-frame file))
 	   (t            (view-file file))))
 	(t
--- a/lisp/progmodes/gdb-ui.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/progmodes/gdb-ui.el	Tue Jan 22 23:53:46 2008 +0000
@@ -1214,10 +1214,12 @@
 
 (defun gdb-dequeue-input ()
   (let ((queue gdb-input-queue))
-    (and queue
-	 (let ((last (car (last queue))))
-	   (unless (nbutlast queue) (setq gdb-input-queue '()))
-	   last))))
+    (if queue
+	(let ((last (car (last queue))))
+	  (unless (nbutlast queue) (setq gdb-input-queue '()))
+	  last)
+      ;; This should be nil here anyway but set it just to make sure.
+      (setq gdb-pending-triggers nil))))
 
 (defun gdb-send-item (item)
   (setq gdb-flush-pending-output nil)
@@ -3445,7 +3447,8 @@
       (let ((buffer (marker-buffer gud-overlay-arrow-position))
 	    (position (marker-position gud-overlay-arrow-position)))
 	(when (and buffer
-		   (string-equal (buffer-name buffer)
+		   (string-equal (file-name-nondirectory
+				  (buffer-file-name buffer))
 				 (file-name-nondirectory (match-string 3))))
 	  (with-current-buffer buffer
 	    (setq fringe-indicator-alist
--- a/lisp/progmodes/sh-script.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/progmodes/sh-script.el	Tue Jan 22 23:53:46 2008 +0000
@@ -1186,6 +1186,7 @@
 This value is used for the `+' and `-' symbols in an indentation variable."
   :type 'integer
   :group 'sh-indentation)
+(put 'sh-basic-offset 'safe-local-variable 'integerp)
 
 (defcustom sh-indent-comment nil
   "How a comment line is to be indented.
--- a/lisp/progmodes/verilog-mode.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/progmodes/verilog-mode.el	Tue Jan 22 23:53:46 2008 +0000
@@ -11,6 +11,12 @@
 ;;	http://www.veripool.com
 ;; Keywords: languages
 
+;;    This code supports Emacs 21.1 and later
+;;    And XEmacs 21.1 and later
+;;    Please do not make changes that break Emacs 21.  Thanks!
+;;
+;;
+
 ;; This file is part of GNU Emacs.
 
 ;; GNU Emacs is free software; you can redistribute it and/or modify
@@ -30,12 +36,12 @@
 
 ;;; Commentary:
 
-;; This mode borrows heavily from the Pascal-mode and the cc-mode of emacs
+;; This mode borrows heavily from the Pascal-mode and the cc-mode of Emacs
 
 ;; USAGE
 ;; =====
 
-;; A major mode for editing Verilog HDL source code. When you have
+;; A major mode for editing Verilog HDL source code.  When you have
 ;; entered Verilog mode, you may get more info by pressing C-h m. You
 ;; may also get online help describing various functions by: C-h f
 ;; <Name of function you want described>
@@ -44,8 +50,8 @@
 ;; =======================
 
 ;; Verilog is a rapidly evolving language, and hence this mode is
-;; under continuous development. Hence this is beta code, and likely
-;; has bugs. Please report any and all bugs to me at mac@verilog.com.
+;; under continuous development.  Hence this is beta code, and likely
+;; has bugs.  Please report any and all bugs to me at mac@verilog.com.
 ;; Please use verilog-submit-bug-report to submit a report; type C-c
 ;; C-b to invoke this and as a result I will have a much easier time
 ;; of reproducing the bug you find, and hence fixing it.
@@ -55,7 +61,7 @@
 
 ;; An older version of this mode may be already installed as a part of
 ;; your environment, and one method of updating would be to update
-;; your emacs environment.  Sometimes this is difficult for local
+;; your Emacs environment.  Sometimes this is difficult for local
 ;; political/control reasons, and hence you can always install a
 ;; private copy (or even a shared copy) which overrides the system
 ;; default.
@@ -74,7 +80,7 @@
 
 ;; If you want to customize Verilog mode to fit your needs better,
 ;; you may add these lines (the values of the variables presented
-;; here are the defaults). Note also that if you use an emacs that
+;; here are the defaults). Note also that if you use an Emacs that
 ;; supports custom, it's probably better to use the custom menu to
 ;; edit these.
 ;;
@@ -102,15 +108,19 @@
 ;; 
 
 ;;; History:
-;;
-;; 
+;; 
+;; See commit history at http://www.veripool.com/verilog-mode.html
+;; (This section is required to appease checkdoc.)
+
 ;;; Code:
 
 ;; This variable will always hold the version number of the mode
-(defconst verilog-mode-version "377"
+(defconst verilog-mode-version "383"
   "Version of this verilog mode.")
-(defconst verilog-mode-release-date "2007-12-07"
-  "Version of this verilog mode.")
+(defconst verilog-mode-release-date "2008-01-07-GNU"
+  "Release date of this verilog mode.")
+(defconst verilog-mode-release-emacs t
+  "If non-nil, this version of verilog mode was released with Emacs itself.")
 
 (defun verilog-version ()
   "Inform caller of the version of this file."
@@ -118,7 +128,10 @@
   (message "Using verilog-mode version %s" verilog-mode-version))
 
 ;; Insure we have certain packages, and deal with it if we don't
+;; Be sure to note which Emacs flavor and version added each feature.
 (eval-when-compile
+  ;; The below were disabled when GNU Emacs 22 was released;
+  ;; perhaps some still need to be there to support Emacs 21.
   (when (featurep 'xemacs)
     (condition-case nil
         (require 'easymenu)
@@ -181,8 +194,8 @@
                       result)
                   (buffer-substring-no-properties (match-beginning num)
                                                   (match-end num)
-                                                  (current-buffer)
-                                                  )))))
+                                                  (current-buffer)))))
+	  )
       (error nil))
     (if (and (featurep 'custom) (fboundp 'custom-declare-variable))
         nil ;; We've got what we needed
@@ -210,6 +223,8 @@
 ;; Provide a regular expression optimization routine, using regexp-opt
 ;; if provided by the user's elisp libraries
 (eval-and-compile
+  ;; The below were disabled when GNU Emacs 22 was released;
+  ;; perhaps some still need to be there to support Emacs 21.
   (if (featurep 'xemacs)
       (if (fboundp 'regexp-opt)
           ;; regexp-opt is defined, does it take 3 or 2 arguments?
@@ -222,8 +237,7 @@
                       (defun verilog-regexp-opt (a b)
                         "Deal with differing number of required arguments for  `regexp-opt'.
          Call 'regexp-opt' on A and B."
-                        (regexp-opt a b 't)
-                        )
+                        (regexp-opt a b 't))
                     (error nil))
                   )
                  ((eq args 2) ;; It takes 2
@@ -261,6 +275,12 @@
   (if (fboundp 'customize-apropos)
       (customize-apropos "font-lock-*" 'faces)))
 
+(defun verilog-booleanp (value)
+  "Return t if VALUE is boolean.
+ This implements GNU Emacs 22.1's `booleanp' function in earlier Emacs.
+ This function may be removed when Emacs 21 is no longer supported."
+  (or (equal value t) (equal value nil)))
+
 (defgroup verilog-mode nil
   "Facilitates easy editing of Verilog source text"
   :group 'languages)
@@ -290,6 +310,7 @@
 you to the next lint error."
   :type 'string
   :group 'verilog-mode-actions)
+;; We don't mark it safe, as it's used as a shell command
 
 (defcustom verilog-coverage
   "echo 'No verilog-coverage set, see \"M-x describe-variable verilog-coverage\"'"
@@ -299,6 +320,7 @@
 you to the next lint error."
   :type 'string
   :group 'verilog-mode-actions)
+;; We don't mark it safe, as it's used as a shell command
 
 (defcustom verilog-simulator
   "echo 'No verilog-simulator set, see \"M-x describe-variable verilog-simulator\"'"
@@ -308,6 +330,7 @@
 you to the next lint error."
   :type 'string
   :group 'verilog-mode-actions)
+;; We don't mark it safe, as it's used as a shell command
 
 (defcustom verilog-compiler
   "echo 'No verilog-compiler set, see \"M-x describe-variable verilog-compiler\"'"
@@ -317,6 +340,7 @@
 you to the next lint error."
   :type 'string
   :group 'verilog-mode-actions)
+;; We don't mark it safe, as it's used as a shell command
 
 (defvar verilog-tool 'verilog-linter
   "Which tool to use for building compiler-command.
@@ -336,11 +360,14 @@
 entry \"Fontify Buffer\").  XEmacs: turn off and on font locking."
   :type 'boolean
   :group 'verilog-mode-indent)
+;; Note we don't use :safe, as that would break on Emacsen before 22.0.
+(put 'verilog-highlight-translate-off 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-indent-level 3
   "*Indentation of Verilog statements with respect to containing block."
   :group 'verilog-mode-indent
   :type 'integer)
+(put 'verilog-indent-level 'safe-local-variable 'integerp)
 
 (defcustom verilog-indent-level-module 3
   "*Indentation of Module level Verilog statements.  (eg always, initial)
@@ -348,12 +375,14 @@
 your screen."
   :group 'verilog-mode-indent
   :type 'integer)
+(put 'verilog-indent-level-module 'safe-local-variable 'integerp)
 
 (defcustom verilog-indent-level-declaration 3
   "*Indentation of declarations with respect to containing block.
 Set to 0 to get them list right under containing block."
   :group 'verilog-mode-indent
   :type 'integer)
+(put 'verilog-indent-level-declaration 'safe-local-variable 'integerp)
 
 (defcustom verilog-indent-declaration-macros nil
   "*How to treat macro expansions in a declaration.
@@ -367,6 +396,7 @@
 	output       c;"
   :group 'verilog-mode-indent
   :type 'boolean)
+(put 'verilog-indent-declaration-macros 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-indent-lists t
   "*How to treat indenting items in a list.
@@ -379,62 +409,73 @@
 	   reset ) begin"
   :group 'verilog-mode-indent
   :type 'boolean)
+(put 'verilog-indent-lists 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-indent-level-behavioral 3
   "*Absolute indentation of first begin in a task or function block.
 Set to 0 to get such code to start at the left side of the screen."
   :group 'verilog-mode-indent
   :type 'integer)
+(put 'verilog-indent-level-behavioral 'safe-local-variable 'integerp)
 
 (defcustom verilog-indent-level-directive 1
   "*Indentation to add to each level of `ifdef declarations.
 Set to 0 to have all directives start at the left side of the screen."
   :group 'verilog-mode-indent
   :type 'integer)
+(put 'verilog-indent-level-directive 'safe-local-variable 'integerp)
 
 (defcustom verilog-cexp-indent 2
   "*Indentation of Verilog statements split across lines."
   :group 'verilog-mode-indent
   :type 'integer)
+(put 'verilog-cexp-indent 'safe-local-variable 'integerp)
 
 (defcustom verilog-case-indent 2
   "*Indentation for case statements."
   :group 'verilog-mode-indent
   :type 'integer)
+(put 'verilog-case-indent 'safe-local-variable 'integerp)
 
 (defcustom verilog-auto-newline t
   "*True means automatically newline after semicolons."
   :group 'verilog-mode-indent
   :type 'boolean)
+(put 'verilog-auto-newline 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-auto-indent-on-newline t
   "*True means automatically indent line after newline."
   :group 'verilog-mode-indent
   :type 'boolean)
+(put 'verilog-auto-indent-on-newline 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-tab-always-indent t
   "*True means TAB should always re-indent the current line.
 Nil means TAB will only reindent when at the beginning of the line."
   :group 'verilog-mode-indent
   :type 'boolean)
+(put 'verilog-tab-always-indent 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-tab-to-comment nil
   "*True means TAB moves to the right hand column in preparation for a comment."
   :group 'verilog-mode-actions
   :type 'boolean)
+(put 'verilog-tab-to-comment 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-indent-begin-after-if t
   "*If true, indent begin statements following if, else, while, for and repeat.
 Otherwise, line them up."
   :group 'verilog-mode-indent
-  :type 'boolean )
+  :type 'boolean)
+(put 'verilog-indent-begin-after-if 'safe-local-variable 'verilog-booleanp)
 
 
 (defcustom verilog-align-ifelse nil
   "*If true, align `else' under matching `if'.
 Otherwise else is lined up with first character on line holding matching if."
   :group 'verilog-mode-indent
-  :type 'boolean )
+  :type 'boolean)
+(put 'verilog-align-ifelse 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-minimum-comment-distance 10
   "*Minimum distance (in lines) between begin and end required before a comment.
@@ -442,6 +483,7 @@
 default avoids too many redundant comments in tight quarters"
   :group 'verilog-mode-indent
   :type 'integer)
+(put 'verilog-minimum-comment-distance 'safe-local-variable 'integerp)
 
 (defcustom verilog-auto-lineup '(declaration)
   "*Algorithm for lining up statements on multiple lines.
@@ -481,23 +523,26 @@
 ;
 
   :group 'verilog-mode-indent
-  :type 'list )
+  :type 'list)
+(put 'verilog-auto-lineup 'safe-local-variable 'listp)
 
 (defcustom verilog-highlight-p1800-keywords nil
-  "*If true highlight words newly reserved by IEEE-1800 in
-verilog-font-lock-p1800-face in order to gently suggest changing where
-these words are used as variables to something else.  Nil means highlight
-these words as appropriate for the SystemVerilog IEEE-1800 standard.  Note
-that changing this will require restarting emacs to see the effect as font
-color choices are cached by emacs"
+  "*True means highlight words newly reserved by IEEE-1800.
+These will appear in `verilog-font-lock-p1800-face' in order to gently
+suggest changing where these words are used as variables to something else.
+Nil means highlight these words as appropriate for the SystemVerilog
+IEEE-1800 standard.  Note that changing this will require restarting Emacs
+to see the effect as font color choices are cached by Emacs"
   :group 'verilog-mode-indent
   :type 'boolean)
+(put 'verilog-highlight-p1800-keywords 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-auto-endcomments t
   "*True means insert a comment /* ... */ after 'end's.
 The name of the function or case will be set between the braces."
   :group 'verilog-mode-actions
-  :type 'boolean )
+  :type 'boolean)
+(put 'verilog-auto-endcomments 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-auto-read-includes nil
   "*True means to automatically read includes before AUTOs.
@@ -506,7 +551,8 @@
 but can result in very slow reading times if there are many or large
 include files."
   :group 'verilog-mode-actions
-  :type 'boolean )
+  :type 'boolean)
+(put 'verilog-auto-read-includes 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-auto-save-policy nil
   "*Non-nil indicates action to take when saving a Verilog buffer with AUTOs.
@@ -527,6 +573,7 @@
 instantiation.  See also `verilog-auto-star' and `verilog-auto-star-save'."
   :group 'verilog-mode-actions
   :type 'boolean)
+(put 'verilog-auto-star-expand 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-auto-star-save nil
   "*Non-nil indicates to save to disk SystemVerilog .* instance expansions.
@@ -537,6 +584,7 @@
 always be saved."
   :group 'verilog-mode-actions
   :type 'boolean)
+(put 'verilog-auto-star-save 'safe-local-variable 'verilog-booleanp)
 
 (defvar verilog-auto-update-tick nil
   "Modification tick at which autos were last performed.")
@@ -624,8 +672,7 @@
     ("In file \\([^ \t]+\\)[ \t]+line[ \t]+\\([0-9]+\\):\n[^\n]*\n[^\n]*\n\\[\\(Warning\\|Error\\|Failure\\)\\][^\n]*" 1 bold t)
     ("In file \\([^ \t]+\\)[ \t]+line[ \t]+\\([0-9]+\\):\n[^\n]*\n[^\n]*\n\\[\\(Warning\\|Error\\|Failure\\)\\][^\n]*" 2 bold t)
     )
-  "*Keywords to also highlight in Verilog *compilation* buffers."
-  )
+  "*Keywords to also highlight in Verilog *compilation* buffers.")
 
 (defcustom verilog-library-flags '("")
   "*List of standard Verilog arguments to use for /*AUTOINST*/.
@@ -656,6 +703,7 @@
 See also the variables mentioned above."
   :group 'verilog-mode-auto
   :type '(repeat string))
+(put 'verilog-library-flags 'safe-local-variable 'listp)
 
 (defcustom verilog-library-directories '(".")
   "*List of directories when looking for files for /*AUTOINST*/.
@@ -678,9 +726,11 @@
 and `verilog-library-extensions'."
   :group 'verilog-mode-auto
   :type '(repeat file))
+(put 'verilog-library-directories 'safe-local-variable 'listp)
 
 (defcustom verilog-library-files '()
-  "*List of files to search for modules when looking for AUTOINST files.
+  "*List of files to search for modules.
+AUTOINST will use this when it needs to resolve a module name.
 This is a complete path, usually to a technology file with many standard
 cells defined in it.
 
@@ -698,12 +748,14 @@
 See also `verilog-library-flags', `verilog-library-directories'."
   :group 'verilog-mode-auto
   :type '(repeat directory))
+(put 'verilog-library-files 'safe-local-variable 'listp)
 
 (defcustom verilog-library-extensions '(".v")
   "*List of extensions to use when looking for files for /*AUTOINST*/.
 See also `verilog-library-flags', `verilog-library-directories'."
   :type '(repeat string)
   :group 'verilog-mode-auto)
+(put 'verilog-library-extensions 'safe-local-variable 'listp)
 
 (defcustom verilog-active-low-regexp nil
   "*If set, treat signals matching this regexp as active low.
@@ -711,21 +763,24 @@
 you will probably also need `verilog-auto-reset-widths' set."
   :group 'verilog-mode-auto
   :type 'string)
+(put 'verilog-active-low-regexp 'safe-local-variable 'stringp)
 
 (defcustom verilog-auto-sense-include-inputs nil
   "*If true, AUTOSENSE should include all inputs.
 If nil, only inputs that are NOT output signals in the same block are
 included."
-  :type 'boolean
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'boolean)
+(put 'verilog-auto-sense-include-inputs 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-auto-sense-defines-constant nil
   "*If true, AUTOSENSE should assume all defines represent constants.
 When true, the defines will not be included in sensitivity lists.  To
 maintain compatibility with other sites, this should be set at the bottom
 of each verilog file that requires it, rather than being set globally."
-  :type 'boolean
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'boolean)
+(put 'verilog-auto-sense-defines-constant 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-auto-reset-widths t
   "*If true, AUTORESET should determine the width of signals.
@@ -735,11 +790,13 @@
 the MSB or LSB of a signal inside a AUTORESET."
   :type 'boolean
   :group 'verilog-mode-auto)
+(put 'verilog-auto-reset-widths 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-assignment-delay ""
   "*Text used for delays in delayed assignments.  Add a trailing space if set."
-  :type 'string
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'string)
+(put 'verilog-assignment-delay 'safe-local-variable 'stringp)
 
 (defcustom verilog-auto-inst-vector t
   "*If true, when creating default ports with AUTOINST, use bus subscripts.
@@ -748,7 +805,8 @@
 declare the wire to have the subscripts removed.)  Nil may speed up some
 simulators, but is less general and harder to read, so avoid."
   :group 'verilog-mode-auto
-  :type 'boolean )
+  :type 'boolean)
+(put 'verilog-auto-inst-vector 'safe-local-variable 'verilog-booleanp)
 
 (defcustom verilog-auto-inst-template-numbers nil
   "*If true, when creating templated ports with AUTOINST, add a comment.
@@ -756,7 +814,8 @@
 port declaration.  Setting this aids in debugging, but nil is suggested for
 regular use to prevent large numbers of merge conflicts."
   :group 'verilog-mode-auto
-  :type 'boolean )
+  :type 'boolean)
+(put 'verilog-auto-inst-template-numbers 'safe-local-variable 'verilog-booleanp)
 
 (defvar verilog-auto-inst-column 40
   "Column number for first part of auto-inst.")
@@ -765,31 +824,36 @@
   "*If set, when creating AUTOINPUT list, ignore signals matching this regexp.
 See the \\[verilog-faq] for examples on using this."
   :group 'verilog-mode-auto
-  :type 'string )
+  :type 'string)
+(put 'verilog-auto-input-ignore-regexp 'safe-local-variable 'stringp)
 
 (defcustom verilog-auto-inout-ignore-regexp nil
   "*If set, when creating AUTOINOUT list, ignore signals matching this regexp.
 See the \\[verilog-faq] for examples on using this."
   :group 'verilog-mode-auto
-  :type 'string )
+  :type 'string)
+(put 'verilog-auto-inout-ignore-regexp 'safe-local-variable 'stringp)
 
 (defcustom verilog-auto-output-ignore-regexp nil
   "*If set, when creating AUTOOUTPUT list, ignore signals matching this regexp.
 See the \\[verilog-faq] for examples on using this."
   :group 'verilog-mode-auto
-  :type 'string )
+  :type 'string)
+(put 'verilog-auto-output-ignore-regexp 'safe-local-variable 'stringp)
 
 (defcustom verilog-auto-unused-ignore-regexp nil
   "*If set, when creating AUTOUNUSED list, ignore signals matching this regexp.
 See the \\[verilog-faq] for examples on using this."
   :group 'verilog-mode-auto
-  :type 'string )
+  :type 'string)
+(put 'verilog-auto-unused-ignore-regexp 'safe-local-variable 'stringp)
 
 (defcustom verilog-typedef-regexp nil
   "*If non-nil, regular expression that matches Verilog-2001 typedef names.
 For example, \"_t$\" matches typedefs named with _t, as in the C language."
   :group 'verilog-mode-auto
-  :type 'string )
+  :type 'string)
+(put 'verilog-typedef-regexp 'safe-local-variable 'stringp)
 
 (defcustom verilog-mode-hook   'verilog-set-compile-command
   "*Hook (List of functions) run after verilog mode is loaded."
@@ -798,33 +862,33 @@
 
 (defcustom verilog-auto-hook nil
   "*Hook run after `verilog-mode' updates AUTOs."
-  :type 'hook
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'hook)
 
 (defcustom verilog-before-auto-hook nil
   "*Hook run before `verilog-mode' updates AUTOs."
-  :type 'hook
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'hook)
 
 (defcustom verilog-delete-auto-hook nil
   "*Hook run after `verilog-mode' deletes AUTOs."
-  :type 'hook
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'hook)
 
 (defcustom verilog-before-delete-auto-hook nil
   "*Hook run before `verilog-mode' deletes AUTOs."
-  :type 'hook
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'hook)
 
 (defcustom verilog-getopt-flags-hook nil
   "*Hook run after `verilog-getopt-flags' determines the Verilog option lists."
-  :type 'hook
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'hook)
 
 (defcustom verilog-before-getopt-flags-hook nil
   "*Hook run before `verilog-getopt-flags' determines the Verilog option lists."
-  :type 'hook
-  :group 'verilog-mode-auto)
+  :group 'verilog-mode-auto
+  :type 'hook)
 
 (defvar verilog-imenu-generic-expression
   '((nil "^\\s-*\\(\\(m\\(odule\\|acromodule\\)\\)\\|primitive\\)\\s-+\\([a-zA-Z0-9_.:]+\\)" 4)
@@ -843,13 +907,11 @@
 (defvar verilog-company nil
   "*Default name of Company for verilog header.
 If set will become buffer local.")
-
 (make-variable-buffer-local 'verilog-company)
 
 (defvar verilog-project nil
   "*Default name of Project for verilog header.
 If set will become buffer local.")
-
 (make-variable-buffer-local 'verilog-project)
 
 (defvar verilog-mode-map
@@ -871,7 +933,6 @@
     (define-key map "\M-\r"    `electric-verilog-terminate-and-indent)
     (define-key map "\M-\t"    'verilog-complete-word)
     (define-key map "\M-?"     'verilog-show-completions)
-    (define-key map [(meta control h)] 'verilog-mark-defun)
     (define-key map "\C-c\`"   'verilog-lint-off)
     (define-key map "\C-c\*"   'verilog-delete-auto-star-implicit)
     (define-key map "\C-c\C-r" 'verilog-label-be)
@@ -881,8 +942,10 @@
     (define-key map "\M-*"     'verilog-star-comment)
     (define-key map "\C-c\C-c" 'verilog-comment-region)
     (define-key map "\C-c\C-u" 'verilog-uncomment-region)
-    (define-key map "\M-\C-a"  'verilog-beg-of-defun)
-    (define-key map "\M-\C-e"  'verilog-end-of-defun)
+    (when (featurep 'xemacs)
+      (define-key map [(meta control h)] 'verilog-mark-defun)
+      (define-key map "\M-\C-a"  'verilog-beg-of-defun)
+      (define-key map "\M-\C-e"  'verilog-end-of-defun))
     (define-key map "\C-c\C-d" 'verilog-goto-defun)
     (define-key map "\C-c\C-k" 'verilog-delete-auto)
     (define-key map "\C-c\C-a" 'verilog-auto)
@@ -895,7 +958,7 @@
 
 ;; menus
 (defvar verilog-xemacs-menu
-  '("Verilog"
+  `("Verilog"
     ("Choose Compilation Action"
      ["None"
       (progn
@@ -929,9 +992,15 @@
       :selected (equal verilog-tool `verilog-compiler)]
      )
     ("Move"
-     ["Beginning of function"		verilog-beg-of-defun t]
-     ["End of function"			verilog-end-of-defun t]
-     ["Mark function"			verilog-mark-defun t]
+     ,(if (featurep 'xemacs)
+	  (progn 
+	    ["Beginning of function"		verilog-beg-of-defun t]
+	    ["End of function"			verilog-end-of-defun t]
+	    ["Mark function"			verilog-mark-defun t])
+	["Beginning of function"		beginning-of-defun t]
+	["End of function"			end-of-defun t]
+	["Mark function"			mark-defun t])
+	
      ["Goto function/module"		verilog-goto-defun t]
      ["Move to beginning of block"	electric-verilog-backward-sexp t]
      ["Move to end of block"		electric-verilog-forward-sexp t]
@@ -1025,8 +1094,7 @@
     ["Casex"		verilog-sk-casex t]
     ["Casez"		verilog-sk-casez t]
     )
-  "Menu for statement templates in Verilog."
-  )
+  "Menu for statement templates in Verilog.")
 
 (easy-menu-define verilog-menu verilog-mode-map "Menu for Verilog mode"
 		  verilog-xemacs-menu)
@@ -1072,8 +1140,7 @@
 		 (store-match-data '(nil nil))
 		 (if BOUND
 		     (< (point) BOUND)
-		   t)
-		 ))))
+		   t)))))
   (match-end 0))
 
 (defsubst verilog-re-search-backward (REGEXP BOUND NOERROR)
@@ -1087,8 +1154,7 @@
 		 (store-match-data '(nil nil))
 		 (if BOUND
 		     (> (point) BOUND)
-		   t)
-		 ))))
+		   t)))))
   (match-end 0))
 
 (defsubst verilog-re-search-forward-quick (regexp bound noerror)
@@ -1130,6 +1196,8 @@
   (save-excursion
     (nth 3 (parse-partial-sexp (verilog-get-beg-of-line) (point)))))
 
+(defvar compile-command)
+
 ;; compilation program
 (defun verilog-set-compile-command ()
   "Function to compute shell command to compile verilog.
@@ -1201,8 +1269,7 @@
 	(setq compilation-error-regexp-alist
 	      (default-value 'compilation-error-regexp-alist))
 	(set (make-local-variable 'compilation-error-regexp-alist)
-	     (default-value 'compilation-error-regexp-alist))
-	)))
+	     (default-value 'compilation-error-regexp-alist)))))
 
 (add-hook 'compilation-mode-hook 'verilog-error-regexp-add)
 
@@ -1330,8 +1397,7 @@
        "endprogram"
        "endsequence"
        "endclocking"
-       )
-     )))
+       ))))
 
 
 (defconst verilog-endcomment-reason-re
@@ -1655,157 +1721,37 @@
  )
  "List of Verilog keywords.")
 
-
-(defconst verilog-emacs-features
-  ;; Documentation at the bottom
-  (let ((major (and (boundp 'emacs-major-version)
-		    emacs-major-version))
-	(minor (and (boundp 'emacs-minor-version)
-		    emacs-minor-version))
-	flavor comments flock-syntax)
-    ;; figure out version numbers if not already discovered
-    (and (or (not major) (not minor))
-	 (string-match "\\([0-9]+\\).\\([0-9]+\\)" emacs-version)
-	 (setq major (string-to-number (substring emacs-version
-					       (match-beginning 1)
-					       (match-end 1)))
-	       minor (string-to-number (substring emacs-version
-					       (match-beginning 2)
-					       (match-end 2)))))
-    (if (not (and major minor))
-	(error "Cannot figure out the major and minor version numbers"))
-    ;; calculate the major version
-    (cond
-     ((= major 4)  (setq major 'v18))	;Epoch 4
-     ((= major 18) (setq major 'v18))	;Emacs 18
-     ((= major 19) (setq major 'v19	;Emacs 19
-			 flavor (if (or (string-match "Lucid" emacs-version)
-					(string-match "XEmacs" emacs-version))
-				    'XEmacs 'FSF)))
-     ((> major 19) (setq major 'v20
-			 flavor (if (or (string-match "Lucid" emacs-version)
-					(string-match "XEmacs" emacs-version))
-				    'XEmacs 'FSF)))
-     ;; I don't know
-     (t (error "Cannot recognize major version number: %s" major)))
-    ;; XEmacs 19 uses 8-bit modify-syntax-entry flags, as do all
-    ;; patched Emacs 19, Emacs 18, Epoch 4's.  Only Emacs 19 uses a
-    ;; 1-bit flag.  Let's be as smart as we can about figuring this
-    ;; out.
-    (if (or (eq major 'v20) (eq major 'v19))
-	(let ((table (copy-syntax-table)))
-	  (modify-syntax-entry ?a ". 12345678" table)
-	  (cond
-	   ;; XEmacs pre 20 and Emacs pre 19.30 use vectors for syntax tables.
-	   ((vectorp table)
-	    (if (= (logand (lsh (aref table ?a) -16) 255) 255)
-		(setq comments '8-bit)
-	      (setq comments '1-bit)))
-	   ;; XEmacs 20 is known to be 8-bit
-	   ((eq flavor 'XEmacs) (setq comments '8-bit))
-	   ;; Emacs 19.30 and beyond are known to be 1-bit
-	   ((eq flavor 'FSF) (setq comments '1-bit))
-	   ;; Don't know what this is
-	   (t (error "Couldn't figure out syntax table format"))
-	   ))
-      ;; Emacs 18 has no support for dual comments
-      (setq comments 'no-dual-comments))
-    ;; determine whether to use old or new font lock syntax
-    ;; We can assume 8-bit syntax table emacsen support new syntax, otherwise
-    ;; look for version > 19.30
-    (setq flock-syntax
-        (if (or (equal comments '8-bit)
-                (equal major 'v20)
-                (and (equal major 'v19) (> minor 30)))
-            'flock-syntax-after-1930
-          'flock-syntax-before-1930))
-    ;; lets do some minimal sanity checking.
-    (if (or
-	 ;; Emacs before 19.6 had bugs
-	 (and (eq major 'v19) (eq flavor 'XEmacs) (< minor 6))
-	 ;; Emacs 19 before 19.21 has known bugs
-	 (and (eq major 'v19) (eq flavor 'FSF) (< minor 21))
-	 )
-	(with-output-to-temp-buffer "*verilog-mode warnings*"
-	  (print (format
-  "The version of Emacs that you are running, %s,
-has known bugs in its syntax parsing routines which will affect the
-performance of verilog-mode. You should strongly consider upgrading to the
-latest available version.  verilog-mode may continue to work, after a
-fashion, but strange indentation errors could be encountered."
-		     emacs-version))))
-    ;; Emacs 18, with no patch is not too good
-    (if (and (eq major 'v18) (eq comments 'no-dual-comments))
-	(with-output-to-temp-buffer "*verilog-mode warnings*"
-	  (print (format
-  "The version of Emacs 18 you are running, %s,
-has known deficiencies in its ability to handle the dual verilog
-\(and C++) comments, (e.g. the // and /* */ comments). This will
-not be much of a problem for you if you only use the /* */ comments,
-but you really should strongly consider upgrading to one of the latest
-Emacs 19's.  In Emacs 18, you may also experience performance degradations.
-Emacs 19 has some new built-in routines which will speed things up for you.
-Because of these inherent problems, verilog-mode is not supported
-on emacs-18."
-			    emacs-version))))
-    ;; Emacs 18 with the syntax patches are no longer supported
-    (if (and (eq major 'v18) (not (eq comments 'no-dual-comments)))
-	(with-output-to-temp-buffer "*verilog-mode warnings*"
-	  (print (format
-  "You are running a syntax patched Emacs 18 variant.  While this should
-work for you, you may want to consider upgrading to Emacs 19.
-The syntax patches are no longer supported either for verilog-mode."))))
-    (list major comments flock-syntax))
-  "A list of features extant in the Emacs you are using.
-There are many flavors of Emacs out there, each with different
-features supporting those needed by `verilog-mode'.  Here's the current
-supported list, along with the values for this variable:
-
- Vanilla Emacs 18/Epoch 4:   (v18 no-dual-comments flock-syntax-before-1930)
- Emacs 18/Epoch 4 (patch2):  (v18 8-bit flock-syntax-after-1930)
- XEmacs (formerly Lucid) 19: (v19 8-bit flock-syntax-after-1930)
- XEmacs 20:                  (v20 8-bit flock-syntax-after-1930)
- Emacs 19.1-19.30:           (v19 8-bit flock-syntax-before-1930)
- Emacs 19.31-19.xx:          (v19 8-bit flock-syntax-after-1930)
- Emacs20        :            (v20 1-bit flock-syntax-after-1930).")
-
 (defconst verilog-comment-start-regexp "//\\|/\\*"
   "Dual comment value for `comment-start-regexp'.")
 
-(defun verilog-populate-syntax-table (table)
-  "Populate the syntax TABLE."
-  (modify-syntax-entry ?\\ "\\" table)
-  (modify-syntax-entry ?+ "." table)
-  (modify-syntax-entry ?- "." table)
-  (modify-syntax-entry ?= "." table)
-  (modify-syntax-entry ?% "." table)
-  (modify-syntax-entry ?< "." table)
-  (modify-syntax-entry ?> "." table)
-  (modify-syntax-entry ?& "." table)
-  (modify-syntax-entry ?| "." table)
-  (modify-syntax-entry ?` "w" table)
-  (modify-syntax-entry ?_ "w" table)
-  (modify-syntax-entry ?\' "." table)
-)
-
-(defun verilog-setup-dual-comments (table)
-  "Set up TABLE to handle block and line style comments."
-  (cond
-   ((memq '8-bit verilog-emacs-features)
-    ;; XEmacs (formerly Lucid) has the best implementation
-    (modify-syntax-entry ?/  ". 1456" table)
-    (modify-syntax-entry ?*  ". 23"   table)
-    (modify-syntax-entry ?\n "> b"    table)
-    )
-   ((memq '1-bit verilog-emacs-features)
-    ;; Emacs 19 does things differently, but we can work with it
-    (modify-syntax-entry ?/  ". 124b" table)
-    (modify-syntax-entry ?*  ". 23"   table)
-    (modify-syntax-entry ?\n "> b"    table)
-    )
-   ))
-
-(defvar verilog-mode-syntax-table nil
+(defvar verilog-mode-syntax-table
+  (let ((table (make-syntax-table)))
+    ;; Populate the syntax TABLE.
+    (modify-syntax-entry ?\\ "\\" table)
+    (modify-syntax-entry ?+ "." table)
+    (modify-syntax-entry ?- "." table)
+    (modify-syntax-entry ?= "." table)
+    (modify-syntax-entry ?% "." table)
+    (modify-syntax-entry ?< "." table)
+    (modify-syntax-entry ?> "." table)
+    (modify-syntax-entry ?& "." table)
+    (modify-syntax-entry ?| "." table)
+    (modify-syntax-entry ?` "w" table)
+    (modify-syntax-entry ?_ "w" table)
+    (modify-syntax-entry ?\' "." table)
+
+    ;; Set up TABLE to handle block and line style comments.
+    (if (featurep 'xemacs)
+	(progn
+	  ;; XEmacs (formerly Lucid) has the best implementation
+	  (modify-syntax-entry ?/  ". 1456" table)
+	  (modify-syntax-entry ?*  ". 23"   table)
+	  (modify-syntax-entry ?\n "> b"    table))
+      ;; Emacs 19 does things differently, but we can work with it
+      (modify-syntax-entry ?/  ". 124b" table)
+      (modify-syntax-entry ?*  ". 23"   table)
+      (modify-syntax-entry ?\n "> b"    table))
+    table)
   "Syntax table used in `verilog-mode' buffers.")
 
 (defvar verilog-font-lock-keywords nil
@@ -1961,8 +1907,7 @@
 		 'font-lock-type-face))
 	 ;; Fontify Verilog-AMS keywords
 	 (cons (concat "\\<\\(" verilog-ams-keywords "\\)\\>")
-	       'verilog-font-lock-ams-face)
-	 ))
+	       'verilog-font-lock-ams-face)))
 
   (setq verilog-font-lock-keywords-1
 	(append verilog-font-lock-keywords
@@ -1976,15 +1921,12 @@
 		 (list
 		  (concat "\\<function\\>\\s-+\\(integer\\|real\\(time\\)?\\|time\\)\\s-+\\(\\sw+\\)" )
 		       '(1 font-lock-keyword-face)
-		       '(3 font-lock-reference-face prepend)
-		       )
+		       '(3 font-lock-reference-face prepend))
 		 '("\\<function\\>\\s-+\\(\\[[^]]+\\]\\)\\s-+\\(\\sw+\\)"
 		   (1 font-lock-keyword-face)
-		   (2 font-lock-reference-face append)
-		   )
+		   (2 font-lock-reference-face append))
 		 '("\\<function\\>\\s-+\\(\\sw+\\)"
-		   1 'font-lock-reference-face append)
-		 )))
+		   1 'font-lock-reference-face append))))
 
   (setq verilog-font-lock-keywords-2
 	(append verilog-font-lock-keywords-1
@@ -2002,7 +1944,6 @@
 		   0 font-lock-type-face append)
 		 ;; Fontify instantiation names
 		 '("\\([A-Za-z][A-Za-z0-9_]+\\)\\s-*(" 1 font-lock-function-name-face)
-
 		 )))
 
   (setq verilog-font-lock-keywords-3
@@ -2015,15 +1956,14 @@
 		   )))))
 
 
-
 (defun verilog-inside-comment-p ()
   "Check if point inside a nested comment."
   (save-excursion
     (let ((st-point (point)) hitbeg)
       (or (search-backward "//" (verilog-get-beg-of-line) t)
 	  (if (progn
-		;; This is for tricky case //*, we keep searching if /* is
-		;; proceeded by // on same line.
+		;; This is for tricky case //*, we keep searching if /*
+		;; is proceeded by // on same line.
 		(while
 		    (and (setq hitbeg (search-backward "/*" nil t))
 			 (progn
@@ -2048,14 +1988,14 @@
   "Move backward over a sexp."
   (interactive)
   ;; before that see if we are in a comment
-  (verilog-backward-sexp)
-)
+  (verilog-backward-sexp))
+
 (defun electric-verilog-forward-sexp ()
   "Move backward over a sexp."
   (interactive)
   ;; before that see if we are in a comment
-  (verilog-forward-sexp)
-)
+  (verilog-forward-sexp))
+
 ;;;used by hs-minor-mode
 (defun verilog-forward-sexp-function (arg)
   (if (< arg 0)
@@ -2067,19 +2007,16 @@
   (let ((reg)
 	(elsec 1)
 	(found nil)
-	(st (point))
-	)
+	(st (point)))
     (if (not (looking-at "\\<"))
 	(forward-word -1))
     (cond
-     ((verilog-skip-backward-comment-or-string)
-      )
+     ((verilog-skip-backward-comment-or-string))
      ((looking-at "\\<else\\>")
       (setq reg (concat
 		 verilog-end-block-re
 		 "\\|\\(\\<else\\>\\)"
-		 "\\|\\(\\<if\\>\\)"
-		 ))
+		 "\\|\\(\\<if\\>\\)"))
       (while (and (not found)
 		  (verilog-re-search-backward reg nil 'move))
 	(cond
@@ -2094,11 +2031,7 @@
 	  (setq elsec (1- elsec))
 	  (if (= 0 elsec)
 	      ;; Now previous line describes syntax
-	      (setq found 't)
-	    ))
-	 )
-	)
-      )
+	      (setq found 't))))))
      ((looking-at verilog-end-block-re)
       (verilog-leap-to-head))
      ((looking-at "\\(endmodule\\>\\)\\|\\(\\<endprimitive\\>\\)\\|\\(\\<endclass\\>\\)\\|\\(\\<endprogram\\>\\)\\|\\(\\<endinterface\\>\\)\\|\\(\\<endpackage\\>\\)")
@@ -2120,9 +2053,7 @@
 	(backward-sexp 1))))
      (t
       (goto-char st)
-      (backward-sexp))
-     ) ;; cond
-    ))
+      (backward-sexp)))))
 
 (defun verilog-forward-sexp ()
   (let ((reg)
@@ -2132,8 +2063,7 @@
 	(forward-word -1))
     (cond
      ((verilog-skip-forward-comment-or-string)
-      (verilog-forward-syntactic-ws)
-      )
+      (verilog-forward-syntactic-ws))
      ((looking-at verilog-beg-block-re-ordered);; begin|case|fork|class|table|specify|function|task|generate|covergroup|property|sequence|clocking
       (cond
        ((match-end 1) ; end
@@ -2141,8 +2071,7 @@
 	(setq reg "\\(\\<begin\\>\\)\\|\\(\\<end\\>\\)" ))
        ((match-end 2) ; endcase
 	;; Search forward for matching case
-	(setq reg "\\(\\<randcase\\>\\|\\(\\<unique\\>\\s-+\\|\\<priority\\>\\s-+\\)?\\<case[xz]?\\>[^:]\\)\\|\\(\\<endcase\\>\\)" )
-	)
+	(setq reg "\\(\\<randcase\\>\\|\\(\\<unique\\>\\s-+\\|\\<priority\\>\\s-+\\)?\\<case[xz]?\\>[^:]\\)\\|\\(\\<endcase\\>\\)" ))
        ((match-end 3) ; join
 	;; Search forward for matching fork
 	(setq reg "\\(\\<fork\\>\\)\\|\\(\\<join\\(_any\\|_none\\)?\\>\\)" ))
@@ -2173,12 +2102,10 @@
        ((match-end 12) ; endsequence
 	;; Search forward for matching sequence
 	(setq reg "\\(\\<\\(rand\\)?sequence\\>\\)\\|\\(\\<endsequence\\>\\)" )
-	(setq md 3) ; 3 to get to endsequence in the reg above
-	)
+	(setq md 3)) ; 3 to get to endsequence in the reg above
        ((match-end 13) ; endclocking
 	;; Search forward for matching clocking
-	(setq reg "\\(\\<clocking\\>\\)\\|\\(\\<endclocking\\>\\)" ))
-       )
+	(setq reg "\\(\\<clocking\\>\\)\\|\\(\\<endclocking\\>\\)" )))
       (if (forward-word 1)
 	  (catch 'skip
 	    (let ((nest 1))
@@ -2189,9 +2116,7 @@
 		  (if (= 0 nest) ; we are out!
 		      (throw 'skip 1)))
 		 ((match-end 1) ; the opener in reg, so we are deeper now
-		  (setq nest (1+ nest)))))
-	      )))
-      )
+		  (setq nest (1+ nest)))))))))
      ((looking-at (concat
 		   "\\(\\<\\(macro\\)?module\\>\\)\\|"
 		   "\\(\\<primitive\\>\\)\\|"
@@ -2221,9 +2146,7 @@
       (goto-char st)
       (if (= (following-char) ?\) )
 	  (forward-char 1)
-	(forward-sexp 1)))
-     ) ;; cond
-    ))
+	(forward-sexp 1))))))
 
 (defun verilog-declaration-beg ()
   (verilog-re-search-backward verilog-declaration-re (bobp) t))
@@ -2238,8 +2161,7 @@
 		  (list
 		   ;; Fontify things in translate off regions
 		   '(verilog-match-translate-off
-                     (0 'verilog-font-lock-translate-off-face prepend))
-		   ))))
+                     (0 'verilog-font-lock-translate-off-face prepend))))))
   (put 'verilog-mode 'font-lock-defaults
        '((verilog-font-lock-keywords
 	  verilog-font-lock-keywords-1
@@ -2253,23 +2175,7 @@
 
 ;; initialize fontification for Verilog Mode
 (verilog-font-lock-init)
-;; start up message
-(defconst verilog-startup-message-lines
-  '("Please use \\[verilog-submit-bug-report] to report bugs."
-    "Visit http://www.verilog.com to check for updates"
-    ))
-(defvar verilog-startup-message-displayed t)
-(defun verilog-display-startup-message ()
-  (if (not verilog-startup-message-displayed)
-      (if (sit-for 5)
-	  (let ((lines verilog-startup-message-lines))
-	    (message "verilog-mode version %s, released %s; type \\[describe-mode] for help"
-		     verilog-mode-version verilog-mode-release-date)
-	    (setq verilog-startup-message-displayed t)
-	    (while (and (sit-for 4) lines)
-	      (message (substitute-command-keys (car lines)))
-	      (setq lines (cdr lines)))))
-    (message "")))
+
 ;;
 ;;
 ;;  Mode
@@ -2409,14 +2315,10 @@
   (setq major-mode 'verilog-mode)
   (setq mode-name "Verilog")
   (setq local-abbrev-table verilog-mode-abbrev-table)
-  (setq verilog-mode-syntax-table (make-syntax-table))
-  (verilog-populate-syntax-table verilog-mode-syntax-table)
-  (set (make-local-variable 'beginning-of-defun-function) 
+  (set (make-local-variable 'beginning-of-defun-function)
        'verilog-beg-of-defun)
-  (set (make-local-variable 'end-of-defun-function) 
+  (set (make-local-variable 'end-of-defun-function)
        'verilog-end-of-defun)
-  ;; add extra comment syntax
-  (verilog-setup-dual-comments verilog-mode-syntax-table)
   (set-syntax-table verilog-mode-syntax-table)
   (make-local-variable 'indent-line-function)
   (setq indent-line-function 'verilog-indent-line-relative)
@@ -2444,8 +2346,8 @@
 	       (not (assoc "Verilog" current-menubar)))
       ;; (set-buffer-menubar (copy-sequence current-menubar))
       (add-submenu nil verilog-xemacs-menu)
-      (add-submenu nil verilog-stmt-menu)
-      ))
+      (add-submenu nil verilog-stmt-menu)))
+
   ;; Stuff for GNU emacs
   (set (make-local-variable 'font-lock-defaults)
        '((verilog-font-lock-keywords verilog-font-lock-keywords-1
@@ -2472,8 +2374,6 @@
 	  (cons '(verilog-mode-mode  "\\<begin\\>" "\\<end\\>" nil
 			     verilog-forward-sexp-function)
 		hs-special-modes-alist)))
-  ;; Display version splash information.
-  (verilog-display-startup-message)
 
   ;; Stuff for autos
   (add-hook 'write-contents-hooks 'verilog-auto-save-check) ; already local
@@ -2527,27 +2427,19 @@
 	       (progn
 		 (end-of-line)
 		 (delete-horizontal-space)
-		 't
-		 )
-	       )
-	     )
+		 't)))
 	   ;; see if we should line up assignments
 	   (progn
 	     (if (or (memq 'all verilog-auto-lineup)
 		     (memq 'assignments verilog-auto-lineup))
-		 (verilog-pretty-expr)
-	       )
-	     (newline)
-	     )
-	 (forward-line 1)
-	 )
+		 (verilog-pretty-expr))
+	     (newline))
+	 (forward-line 1))
        ;; Indent next line
        (if verilog-auto-indent-on-newline
-	   (verilog-indent-line))
-       )
+	   (verilog-indent-line)))
      (t
-      (newline))
-     )))
+      (newline)))))
 
 (defun electric-verilog-terminate-and-indent ()
   "Insert a newline and indent for the next statement."
@@ -2565,8 +2457,7 @@
     (save-excursion
       (beginning-of-line)
       (verilog-forward-ws&directives)
-      (verilog-indent-line)
-      )
+      (verilog-indent-line))
     (if (and verilog-auto-newline
 	     (not (verilog-parenthesis-depth)))
 	(electric-verilog-terminate-line))))
@@ -2648,9 +2539,7 @@
 		   (re-search-forward comment-start-skip oldpnt 'move)
 		   (goto-char (match-beginning 0))
 		   (skip-chars-backward " \t")
-		   (kill-region (point) oldpnt)
-		   ))))
-	)
+		   (kill-region (point) oldpnt))))))
     (progn (insert "\t"))))
 
 
@@ -2690,7 +2579,7 @@
   (insert " * "))
 
 (defun verilog-insert-1 (fmt max)
-  "Insert integers 0 to MAX-1 according to format string FMT.
+  "Use format string FMT to insert integers 0 to MAX - 1.
 Inserts one integer per line, at the current column.  Stops early
 if it reaches the end of the buffer."
   (let ((col (current-column))
@@ -2724,7 +2613,7 @@
     a = b                           a[  7] = b
     a = b                           a[  8] = b"
 
-  (interactive "NMAX? ")
+  (interactive "NMAX: ")
   (verilog-insert-1 "[%3d]" max))
 
 (defun verilog-generate-numbers (max)
@@ -2744,19 +2633,20 @@
     buf buf                             buf buf007
     buf buf                             buf buf008"
 
-  (interactive "NMAX? ")
+  (interactive "NMAX: ")
   (verilog-insert-1 "%3.3d" max))
 
 (defun verilog-mark-defun ()
   "Mark the current verilog function (or procedure).
 This puts the mark at the end, and point at the beginning."
   (interactive)
-  (push-mark (point))
-  (verilog-end-of-defun)
-  (push-mark (point))
-  (verilog-beg-of-defun)
-  (if (fboundp 'zmacs-activate-region)
-      (zmacs-activate-region)))
+  (when (featurep 'xemacs)
+    (push-mark (point))
+    (verilog-end-of-defun)
+    (push-mark (point))
+    (verilog-beg-of-defun)
+    (if (fboundp 'zmacs-activate-region)
+	(zmacs-activate-region))))
 
 (defun verilog-comment-region (start end)
   ; checkdoc-params: (start end)
@@ -2792,8 +2682,7 @@
     (save-excursion
       (let ((s+1 (1+ start)))
 	(while (re-search-backward "/\\*" s+1 t)
-	  (replace-match "/-*" t t))))
-    ))
+	  (replace-match "/-*" t t))))))
 
 (defun verilog-uncomment-region ()
   "Uncomment a commented area; change deformed comments back to normal.
@@ -2869,8 +2758,7 @@
 	     (point-marker)))
 	(e (progn
 	     (verilog-end-of-defun)
-	     (point-marker)))
-	)
+	     (point-marker))))
     (goto-char (marker-position b))
     (if (> (- e b) 200)
 	(message  "Relabeling module..."))
@@ -2885,18 +2773,15 @@
       (let ((indent-str (verilog-indent-line)))
 	(verilog-set-auto-endcomments indent-str 't)
 	(end-of-line)
-	(delete-horizontal-space)
-	)
+	(delete-horizontal-space))
       (setq cnt (1+ cnt))
       (if (= 9 (% cnt 10))
-	  (message "%d..." cnt))
-      )
+	  (message "%d..." cnt)))
     (goto-char oldpos)
     (if (or
 	 (> (- e b) 200)
 	 (> cnt 20))
-	(message  "%d lines auto commented" cnt))
-    ))
+	(message  "%d lines auto commented" cnt))))
 
 (defun verilog-beg-of-statement ()
   "Move backward to beginning of statement."
@@ -2919,15 +2804,13 @@
 	     (looking-at verilog-extended-complete-re)
 	     (not (save-excursion
 		    (verilog-backward-token)
-		    (looking-at verilog-extended-complete-re)))
-	     )
+		    (looking-at verilog-extended-complete-re))))
 	    (looking-at verilog-basic-complete-re)
 	    (save-excursion
 	      (verilog-backward-token)
 	      (or
 	       (looking-at verilog-end-block-re)
-	       (looking-at verilog-preprocessor-re)))
-	    ))
+	       (looking-at verilog-preprocessor-re)))))
     (verilog-backward-syntactic-ws)
     (verilog-backward-token))
   ;; Now point is where the previous line ended.
@@ -3011,9 +2894,9 @@
 		(throw 'found 1))
 		(setq nest (1- nest)))
 	       (t
-		(throw 'found (= nest 0)))
-	       ))))
+		(throw 'found (= nest 0)))))))
       nil)))
+
 (defun verilog-in-struct-region-p ()
   "Return TRUE if in a struct region;
 more specifically, in a list after a struct|union keyword"
@@ -3024,20 +2907,14 @@
       (if depth
 	  (progn (backward-up-list depth)
 		 (verilog-beg-of-statement)
-		 (looking-at "\\<typedef\\>?\\s-*\\<struct\\|union\\>")
-		 )
-	)
-      )
-    )
-  )
+		 (looking-at "\\<typedef\\>?\\s-*\\<struct\\|union\\>"))))))
 
 (defun verilog-in-generate-region-p ()
   "Return TRUE if in a generate region;
 more specifically, after a generate and before an endgenerate"
   (interactive)
   (let ((lim (save-excursion (verilog-beg-of-defun)  (point)))
-	(nest 1)
-	)
+	(nest 1))
     (save-excursion
       (while (and
 	      (/= nest 0)
@@ -3046,17 +2923,14 @@
 	       ((match-end 1) ; generate
 		(setq nest (1- nest)))
 	       ((match-end 2) ; endgenerate
-		(setq nest (1+ nest)))
-	       ))
-	))
+		(setq nest (1+ nest)))))))
     (= nest 0) )) ; return nest
 
 (defun verilog-in-fork-region-p ()
   "Return true if between a fork and join."
   (interactive)
   (let ((lim (save-excursion (verilog-beg-of-defun)  (point)))
-	(nest 1)
-	)
+	(nest 1))
     (save-excursion
       (while (and
 	      (/= nest 0)
@@ -3065,9 +2939,7 @@
 	       ((match-end 1) ; fork
 		(setq nest (1- nest)))
 	       ((match-end 2) ; join
-		(setq nest (1+ nest)))
-	       ))
-	))
+		(setq nest (1+ nest)))))))
     (= nest 0) )) ; return nest
 
 (defun verilog-backward-case-item (lim)
@@ -3099,8 +2971,7 @@
 	      (setq colon (1- colon)))
 
 	     ((match-end 3) ;; :
-	      (setq colon (1+ colon)))
-	     ))
+	      (setq colon (1+ colon)))))
 	  ;; Skip back to beginning of case item
 	  (skip-chars-backward "\t ")
 	  (verilog-skip-backward-comment-or-string)
@@ -3123,10 +2994,8 @@
 			 (t
 			  (goto-char (match-end 0))
 			  (verilog-forward-ws&directives)
-			  (point))
-			 ))
-		    (error "Malformed case item")
-		    )))
+			  (point))))
+		    (error "Malformed case item"))))
 	  (setq str (buffer-substring b e))
 	  (if
 	      (setq e
@@ -3178,8 +3047,7 @@
 		   (search-backward "//" (verilog-get-beg-of-line) t)))))
       (let ((nest 1) b e
 	    m
-	    (else (if (match-end 2) "!" " "))
-	    )
+	    (else (if (match-end 2) "!" " ")))
 	(end-of-line)
 	(if kill-existing-comment
 	    (verilog-kill-existing-comment))
@@ -3199,8 +3067,7 @@
 	     ((match-end 4) ; `ifdef
 	      (setq nest (1- nest)))
 	     ((match-end 5) ; `ifndef
-	      (setq nest (1- nest)))
-	     ))
+	      (setq nest (1- nest)))))
 	  (if (match-end 0)
 	      (setq
 	       m (buffer-substring
@@ -3212,15 +3079,13 @@
 		   (point))
 	       e (progn
 		   (skip-chars-forward "a-zA-Z0-9_")
-		   (point)
-		   ))))
+		   (point)))))
 	(if b
 	    (if (> (count-lines (point) b) verilog-minimum-comment-distance)
 		(insert (concat " // " else m " " (buffer-substring b e))))
 	  (progn
 	    (insert " // unmatched `else or `endif")
-	    (ding 't))
-	  )))
+	    (ding 't)))))
 
      (; Comment close case/class/function/task/module and named block
       (and (looking-at "\\<end")
@@ -3269,8 +3134,7 @@
 		      (err 't)
 		      (here (point))
 		      there
-		      cntx
-		      )
+		      cntx)
 		  (save-excursion
 		    (verilog-leap-to-head)
 		    (setq there (point))
@@ -3282,12 +3146,10 @@
 			      (verilog-kill-existing-comment))
 			  (delete-horizontal-space)
 			  (insert str)
-			  (ding 't)
-			  )
+			  (ding 't))
 		      (let ((lim
 			     (save-excursion (verilog-beg-of-defun) (point)))
-			    (here (point))
-			    )
+			    (here (point)))
 			(cond
 			 (;-- handle named block differently
 			  (looking-at verilog-named-block-re)
@@ -3336,8 +3198,7 @@
 			     (;- else
 			      (match-end 4)
 			      (let ((nest 0)
-				    ( reg "\\(\\<begin\\>\\)\\|\\(\\<end\\>\\)\\|\\(\\<if\\>\\)")
-				    )
+				    ( reg "\\(\\<begin\\>\\)\\|\\(\\<end\\>\\)\\|\\(\\<if\\>\\)"))
 				(catch 'skip
 				  (while (verilog-re-search-backward reg nil 'move)
 				    (cond
@@ -3353,16 +3214,13 @@
 					    (setq err nil)
 					    (setq str (verilog-get-expr))
 					    (setq str (concat " // else: !if" str ))
-					    (throw 'skip 1))
-					)))
-				    ))))
+					    (throw 'skip 1)))))))))
 
 			     (;- end else
 			      (match-end 5)
 			      (goto-char there)
 			      (let ((nest 0)
-				    ( reg "\\(\\<begin\\>\\)\\|\\(\\<end\\>\\)\\|\\(\\<if\\>\\)")
-				    )
+				    (reg "\\(\\<begin\\>\\)\\|\\(\\<end\\>\\)\\|\\(\\<if\\>\\)"))
 				(catch 'skip
 				  (while (verilog-re-search-backward reg nil 'move)
 				    (cond
@@ -3378,9 +3236,7 @@
 					    (setq err nil)
 					    (setq str (verilog-get-expr))
 					    (setq str (concat " // else: !if" str ))
-					    (throw 'skip 1))
-					)))
-				    ))))
+					    (throw 'skip 1)))))))))
 
 			     (;- task/function/initial et cetera
 			      t
@@ -3392,8 +3248,7 @@
 			      (setq str (concat " // " cntx str )))
 
 			     (;-- otherwise...
-			      (setq str " // auto-endcomment confused "))
-			     ))
+			      (setq str " // auto-endcomment confused "))))
 
 			   ((and
 			     (verilog-in-case-region-p) ;-- handle case item differently
@@ -3431,9 +3286,8 @@
 		(match-end 11) ;; of verilog-end-block-ordered-re
 		;;(goto-char there)
 		(let ((nest 0)
-		      ( reg "\\<\\(class\\)\\|\\(endclass\\)\\|\\(package\\|primitive\\|\\(macro\\)?module\\)\\>")
-		      string
-		      )
+		      (reg "\\<\\(class\\)\\|\\(endclass\\)\\|\\(package\\|primitive\\|\\(macro\\)?module\\)\\>")
+		      string)
 		  (save-excursion
 		    (catch 'skip
 		      (while (verilog-re-search-backward reg nil 'move)
@@ -3463,8 +3317,7 @@
 				(throw 'skip 1))))
 			 ))))
 		  (end-of-line)
-		  (insert (concat " // " string )))
-		)
+		  (insert (concat " // " string ))))
 
 	       (;- this is end{function,generate,task,module,primitive,table,generate}
 		;- which can not be nested.
@@ -3479,8 +3332,7 @@
 		  (cond
 		   ((match-end 5) ;; of verilog-end-block-ordered-re
 		    (setq reg "\\(\\<function\\>\\)\\|\\(\\<\\(endfunction\\|task\\|\\(macro\\)?module\\|primitive\\)\\>\\)")
-		    (setq width "\\(\\s-*\\(\\[[^]]*\\]\\)\\|\\(real\\(time\\)?\\)\\|\\(integer\\)\\|\\(time\\)\\)?")
-		    )
+		    (setq width "\\(\\s-*\\(\\[[^]]*\\]\\)\\|\\(real\\(time\\)?\\)\\|\\(integer\\)\\|\\(time\\)\\)?"))
 		   ((match-end 6) ;; of verilog-end-block-ordered-re
 		    (setq reg "\\(\\<task\\>\\)\\|\\(\\<\\(endtask\\|function\\|\\(macro\\)?module\\|primitive\\)\\>\\)"))
 		   ((match-end 7) ;; of verilog-end-block-ordered-re
@@ -3502,8 +3354,7 @@
 		   ((match-end 15) ;; of verilog-end-block-ordered-re
 		    (setq reg "\\(\\<clocking\\>\\)\\|\\<endclocking\\>"))
 
-		   (t (error "Problem in verilog-set-auto-endcomments"))
-		   )
+		   (t (error "Problem in verilog-set-auto-endcomments")))
 		  (let (b e)
 		    (save-excursion
 		      (verilog-re-search-backward reg nil 'move)
@@ -3515,8 +3366,7 @@
 				  (if (and width (looking-at width))
 				      (progn
 					(goto-char (match-end 0))
-					(verilog-forward-ws&directives)
-					))
+					(verilog-forward-ws&directives)))
 				  (point))
 			      e (progn
 				  (skip-chars-forward "a-zA-Z0-9_")
@@ -3577,8 +3427,7 @@
 		b)
 	       ('t
 		(skip-chars-forward "^: \t\n\f")
-		(point)
-		))))
+		(point)))))
 	 (str (buffer-substring b e)))
     (if (setq e (string-match "[ \t]*\\(\\(\n\\)\\|\\(//\\)\\|\\(/\\*\\)\\)" str))
 	(setq str (concat (substring str 0 e) "...")))
@@ -3601,8 +3450,8 @@
 	   (concat "\\(.*\\)"
 		   (regexp-quote bra)
 		   "\\([0-9]*\\)\\(:[0-9]*\\|\\)\\(::[0-9---]*\\|\\)"
-				(regexp-quote ket)
-				"\\(.*\\)$") signal-string)
+		   (regexp-quote ket)
+		   "\\(.*\\)$") signal-string)
 	  (let* ((sig-head (match-string 1 signal-string))
 		 (vec-start (string-to-number (match-string 2 signal-string)))
 		 (vec-end (if (= (match-beginning 3) (match-end 3))
@@ -3765,8 +3614,7 @@
                   )))
                ((verilog-in-star-comment-p)
                 (re-search-backward "/\*")
-                (insert (format " // surefire lint_off_line %6s" code ))
-                )
+                (insert (format " // surefire lint_off_line %6s" code )))
                (t
                 (insert (format " // surefire lint_off_line %6s" code ))
                 )))))))))
@@ -3823,11 +3671,11 @@
    (setq default-major-mode `verilog-mode)
    ;; Ditto files already read in
    (mapc (lambda (buf)
-           (when (buffer-file-name buf)
-             (save-excursion
-               (set-buffer buf)
-               (verilog-mode))))
-         (buffer-list))
+	   (when (buffer-file-name buf)
+	     (save-excursion
+	       (set-buffer buf)
+	       (verilog-mode))))
+	 (buffer-list))
    ;; Process the files
    (mapcar '(lambda (buf)
 	      (when (buffer-file-name buf)
@@ -3943,8 +3791,7 @@
 			(not (verilog-in-coverage))
 			(verilog-in-paren))
 		       (progn (setq par 1)
-			      (throw 'nesting 'block))
-		     )
+			      (throw 'nesting 'block)))
 
 		   ;; See if we are continuing a previous line
 		   (while t
@@ -4026,8 +3873,7 @@
 				   (setq reg "\\(\\<class\\>\\)\\|\\(\\<endclass\\>\\)" ))
 				  ((match-end 12) ; covergroup
 				   ;; Search back for matching covergroup
-				   (setq reg "\\(\\<covergroup\\>\\)\\|\\(\\<endgroup\\>\\)" ))
-				  )
+				   (setq reg "\\(\\<covergroup\\>\\)\\|\\(\\<endgroup\\>\\)" )))
 				 (catch 'skip
 				   (while (verilog-re-search-backward reg nil 'move)
 				     (cond
@@ -4037,11 +3883,8 @@
 					   (throw 'skip 1)))
 				      ((match-end 2) ; end
 				       (setq nest (1+ nest)))))
-				   )
-				 ))
-			      ))))
-		     (throw 'nesting (verilog-calc-1))
-		     )
+				   )))))))
+		     (throw 'nesting (verilog-calc-1)))
 		   );; catch nesting
 		 );; type
 	   )
@@ -4058,8 +3901,8 @@
 	  ((eq type 'defun)
 	   (list type 0))
 	  (t
-	   (list type (verilog-current-indent-level)))))
-      )))
+	   (list type (verilog-current-indent-level))))))))
+
 (defun verilog-wai ()
   "Show matching nesting block for debugging."
   (interactive)
@@ -4073,8 +3916,7 @@
       (cond
        ((equal (char-after) ?\{)
 	(if (verilog-at-constraint-p)
-	    (throw 'nesting 'block)
-	  ))
+	    (throw 'nesting 'block)))
        ((equal (char-after) ?\})
 
 	(let ((there (verilog-at-close-constraint-p)))
@@ -4133,8 +3975,7 @@
 For speed, the searcher looks at the last directive, not the indent
 of the appropriate enclosing block."
   (let ((base -1)	;; Indent of the line that determines our indentation
-	(ind 0)	        ;; Relative offset caused by other directives (like `endif on same line as `else)
-	)
+	(ind 0))        ;; Relative offset caused by other directives (like `endif on same line as `else)
     ;; Start at current location, scan back for another directive
 
     (save-excursion
@@ -4142,8 +3983,7 @@
       (while (and (< base 0)
 		  (verilog-re-search-backward verilog-directive-re nil t))
 	(cond ((save-excursion (skip-chars-backward " \t") (bolp))
-	       (setq base (current-indentation))
-	       ))
+	       (setq base (current-indentation))))
 	(cond ((and (looking-at verilog-directive-end) (< base 0))  ;; Only matters when not at BOL
 	       (setq ind (- ind verilog-indent-level-directive)))
 	      ((and (looking-at verilog-directive-middle) (>= base 0))  ;; Only matters when at BOL
@@ -4223,8 +4063,7 @@
       (setq reg "\\(\\<\\(rand\\)?sequence\\>\\)\\|\\(\\<endsequence\\>\\)" ))
      ((looking-at "\\<endclocking\\>")
       ;; 12: Search back for matching clocking
-      (setq reg "\\(\\<clocking\\)\\|\\(\\<endclocking\\>\\)" ))
-     )
+      (setq reg "\\(\\<clocking\\)\\|\\(\\<endclocking\\>\\)" )))
     (if reg
 	(catch 'skip
 	  (let (sreg)
@@ -4268,9 +4107,7 @@
 			(save-excursion
 			  (skip-chars-backward " \t")
 			  (not (bolp))))
-	    (setq continued (verilog-backward-token))
-	    ) ;; while
-	    ))
+	    (setq continued (verilog-backward-token)))))
       (setq continued nil))
     continued))
 
@@ -4289,15 +4126,13 @@
     (= (preceding-char) ?\})
     (progn
       (backward-char)
-      (verilog-at-close-constraint-p))
-    )
+      (verilog-at-close-constraint-p)))
    (;-- constraint foo { a = b }
     ;   is a complete statement. *sigh*
     (= (preceding-char) ?\{)
     (progn
       (backward-char)
-      (not (verilog-at-constraint-p)))
-    )
+      (not (verilog-at-constraint-p))))
    (;-- Could be 'case (foo)' or 'always @(bar)' which is complete
     ;   also could be simply '@(foo)'
     ;   or foo u1 #(a=8)
@@ -4322,10 +4157,8 @@
 	      (verilog-backward-token)
 	      (not (looking-at "\\<\\(always\\(_latch\\|_ff\\|_comb\\)?\\|initial\\|while\\)\\>"))))
 	   ((= (preceding-char) ?\#)
-	    (backward-char)
-	    )
-	   (t t))
-	  )))))
+	    (backward-char))
+	   (t t)))))))
 
    (;-- any of begin|initial|while are complete statements; 'begin : foo' is also complete
     t
@@ -4346,8 +4179,7 @@
 	  (backward-sexp)
 	  (if (looking-at verilog-nameable-item-re )
 	      nil
-	    t)
-	  )
+	    t))
 	 ((= (preceding-char) ?\#)
 	  (backward-char)
 	  t)
@@ -4357,8 +4189,7 @@
 
 	 (t
 	  (goto-char back)
-	  t)
-	 )))))))
+	  t))))))))
 
 (defun verilog-backward-syntactic-ws (&optional bound)
   "Backward skip over syntactic whitespace for Emacs 19.
@@ -4370,9 +4201,7 @@
 	    (narrow-to-region bound (point))
 	    (while (/= here (point))
 	      (setq here (point))
-	      (verilog-skip-backward-comments)
-	      )))
-      ))
+	      (verilog-skip-backward-comments))))))
   t)
 
 (defun verilog-forward-syntactic-ws (&optional bound)
@@ -4380,16 +4209,13 @@
 Optional BOUND limits search."
   (save-restriction
     (let* ((bound (or bound (point-max)))
-	   (here bound)
-	   )
+	   (here bound))
       (if (> bound (point))
 	  (progn
 	    (narrow-to-region (point) bound)
 	    (while (/= here (point))
 	      (setq here (point))
-	      (forward-comment (buffer-size))
-	      )))
-      )))
+	      (forward-comment (buffer-size))))))))
 
 (defun verilog-backward-ws&directives (&optional bound)
   "Backward skip over syntactic whitespace and compiler directives for Emacs 19.
@@ -4423,9 +4249,7 @@
 			(point))
 		       (t
 			nil))))
-	      (if p (goto-char p))
-	      )))
-      )))
+	      (if p (goto-char p))))))))
 
 (defun verilog-forward-ws&directives (&optional bound)
   "Forward skip over syntactic whitespace and compiler directives for Emacs 19.
@@ -4433,8 +4257,7 @@
   (save-restriction
     (let* ((bound (or bound (point-max)))
 	   (here bound)
-	   jump
-	   )
+	   jump)
       (if (> bound (point))
 	  (progn
 	    (let ((state
@@ -4455,9 +4278,7 @@
 		(if (looking-at verilog-directive-re-1)
 		    (setq jump t)))
 	      (if jump
-		  (beginning-of-line 2))
-	      )))
-      )))
+		  (beginning-of-line 2))))))))
 
 (defun verilog-in-comment-p ()
  "Return true if in a star or // comment."
@@ -4537,14 +4358,11 @@
 	 (forward-list)
 	 (progn (backward-char 1)
 		(verilog-backward-ws&directives)
-		(equal (char-before) ?\;))
-	 ))
+		(equal (char-before) ?\;))))
       ;; maybe
       (verilog-re-search-backward "\\<constraint\\|coverpoint\\|cross\\>" nil 'move)
     ;; not
-    nil
-    )
-  )
+    nil))
 
 (defun verilog-parenthesis-depth ()
  "Return non zero if in parenthetical-expression."
@@ -4608,8 +4426,7 @@
 	       t)
 	      ((and (not (bobp))
 		    (= (char-before) ?\/)
-		    (= (char-before (1- (point))) ?\*)
-		    )
+		    (= (char-before (1- (point))) ?\*))
 	       (goto-char (- (point) 2))
 	       t)
 	      (t
@@ -4650,8 +4467,8 @@
 	    (if (verilog-continued-line)
 		(progn
 		  (goto-char sp)
-		  (setq
-		   indent-str (list 'statement (verilog-current-indent-level))))
+		  (setq indent-str
+			(list 'statement (verilog-current-indent-level))))
 	      (goto-char sp1)
 	      (setq indent-str (list 'block (verilog-current-indent-level)))))
 	  (goto-char sp))
@@ -4701,16 +4518,13 @@
 			     (progn
 			       (forward-char 1)
 			       (backward-up-list -1)
-			       (skip-chars-forward " \t")))
-			    )
+			       (skip-chars-forward " \t"))))
 			   (current-column))
 		       (progn
 			 (goto-char fst)
-			 (+ (current-column) verilog-cexp-indent))
-		       ))))
+			 (+ (current-column) verilog-cexp-indent))))))
 	    (goto-char here)
-	    (indent-line-to val))
-	  )
+	    (indent-line-to val)))
 	 ((= (preceding-char) ?\) )
 	  (goto-char here)
 	  (let ((val (eval (cdr (assoc type verilog-indent-alist)))))
@@ -4724,8 +4538,7 @@
 		(setq val (current-column))
 	      (setq val (eval (cdr (assoc type verilog-indent-alist)))))
 	    (goto-char here)
-	    (indent-line-to val)))
-	 )))
+	    (indent-line-to val))))))
 
      (; handle inside parenthetical expressions
       (eq type 'cparenexp)
@@ -4737,8 +4550,7 @@
 	(indent-line-to val)
 	(if (and (not (verilog-in-struct-region-p))
 		 (looking-at verilog-declaration-re))
-	    (verilog-indent-declaration ind))
-	))
+	    (verilog-indent-declaration ind))))
 
      (;-- Handle the ends
       (or
@@ -4774,8 +4586,8 @@
      (;-- Everything else
       t
       (let ((val (eval (cdr (assoc type verilog-indent-alist)))))
-	(indent-line-to val)))
-     )
+	(indent-line-to val))))
+
     (if (looking-at "[ \t]+$")
 	(skip-chars-forward " \t"))
     indent-str				; Return indent data
@@ -4823,8 +4635,7 @@
 	   (t
 	    (save-excursion
 	      (re-search-backward "//" nil t)
-	      (current-column)))
-	   )))
+	      (current-column))))))
     (indent-line-to stcol)
     stcol))
 
@@ -4843,8 +4654,7 @@
 	   (t
 	    (save-excursion
 	      (re-search-backward "//" nil t)
-	      (current-column)))
-	   )))
+	      (current-column))))))
     (progn
       (indent-to stcol)
       (if (and star
@@ -4912,8 +4722,7 @@
 		  (goto-char start)
 		  (verilog-do-indent (verilog-calculate-indent))
 		  (verilog-forward-ws&directives)
-		  (current-column)))
-	       )
+		  (current-column))))
 	  (goto-char end)
 	  (goto-char start)
 	  (if (> (- end start) 100)
@@ -4927,15 +4736,12 @@
 	       (verilog-forward-ws&directives)
 	       (indent-line-to base-ind)
 	       (verilog-forward-ws&directives)
-	       (verilog-re-search-forward "[ \t\n\f]" e 'move)
-	       )
+	       (verilog-re-search-forward "[ \t\n\f]" e 'move))
 	     (t
 	      (just-one-space)
-	      (verilog-re-search-forward "[ \t\n\f]" e 'move)
-	      )
-	     )
+	      (verilog-re-search-forward "[ \t\n\f]" e 'move)))
+	    ;;(forward-line)
 	    )
-	    ;;(forward-line))
 	  ;; Now find biggest prefix
 	  (setq ind (verilog-get-lineup-indent start edpos))
 	  ;; Now indent each line.
@@ -4960,21 +4766,19 @@
 		      (indent-to ind))
 		  (progn
 		    (just-one-space)
-		    (indent-to ind))
-		  )))
+		    (indent-to ind)))))
 	     ((verilog-continued-line-1 start)
 	      (goto-char e)
 	      (indent-line-to ind))
 	     (t		; Must be comment or white space
 	      (goto-char e)
 	      (verilog-forward-ws&directives)
-	      (forward-line -1))
-	     )
+	      (forward-line -1)))
 	    (forward-line 1))
 	  (message "")))))
 
 (defun verilog-pretty-expr (&optional myre)
-  "Line up expressions around point."
+  "Line up expressions around point, or optional regexp MYRE."
   (interactive "sRegular Expression: ((<|:)?=) ")
   (save-excursion
     (if (or (eq myre nil)
@@ -4995,8 +4799,7 @@
 		  (beginning-of-line)
 		  (while (and (not (looking-at (concat "^\\s-*" verilog-complete-reg)))
 			      (looking-at myre)
-			      (not (bobp))
-			      )
+			      (not (bobp)))
 		    (setq e (point))
 		    (verilog-backward-syntactic-ws)
 		    (beginning-of-line)
@@ -5015,12 +4818,10 @@
 		    (end-of-line)
 		    (setq e (point))
 		    (verilog-forward-syntactic-ws)
-		    (beginning-of-line)
-		    )
+		    (beginning-of-line))
 		  e))
 	       (edpos (set-marker (make-marker) end))
-	       (ind)
-	       )
+	       (ind))
 	  (goto-char start)
 	  (verilog-do-indent (verilog-calculate-indent))
 	  (if (> (- end start) 100)
@@ -5031,8 +4832,7 @@
 	    (beginning-of-line)
 	    (verilog-just-one-space myre)
 	    (end-of-line)
-	    (verilog-forward-syntactic-ws)
-	    )
+	    (verilog-forward-syntactic-ws))
 
 	  ;; Now find biggest prefix
 	  (setq ind (verilog-get-lineup-indent-2 myre start edpos))
@@ -5049,20 +4849,16 @@
 	      (goto-char (match-end 1))
 	      (if (eq (char-after) ?=)
 		  (indent-to (1+ ind))	; line up the = of the <= with surrounding =
-		(indent-to ind)
-		)
-	      )
+		(indent-to ind)))
 	     ((verilog-continued-line-1 start)
 	      (goto-char e)
 	      (indent-line-to ind))
 	     (t		; Must be comment or white space
 	      (goto-char e)
 	      (verilog-forward-ws&directives)
-	      (forward-line -1))
-	     )
+	      (forward-line -1)))
 	    (forward-line 1))
-	  (message "")
-	  ))))
+	  (message "")))))
 
 (defun verilog-just-one-space (myre)
   "Remove extra spaces around regular expression MYRE."
@@ -5073,12 +4869,10 @@
 	    (p2 (match-end 2)))
 	(progn
 	  (goto-char p2)
-	  (if (looking-at "\\s-") (just-one-space) )
+	  (if (looking-at "\\s-") (just-one-space))
 	  (goto-char p1)
 	  (forward-char -1)
-	  (if (looking-at "\\s-") (just-one-space))
-	  )
-	))
+	  (if (looking-at "\\s-") (just-one-space)))))
   (message ""))
 
 (defun verilog-indent-declaration (baseind)
@@ -5093,8 +4887,7 @@
 	       (point)))
 	(ind)
 	(val)
-	(m1 (make-marker))
-	)
+	(m1 (make-marker)))
     (setq val
 	  (+ baseind (eval (cdr (assoc 'declaration verilog-indent-alist)))))
     (indent-line-to val)
@@ -5125,13 +4918,11 @@
 			  (just-one-space)
 			  (goto-char (marker-position m1))
 			  (just-one-space)
-			  (indent-to ind)
-			  )
+			  (indent-to ind))
 		      (if (/= (current-column) ind)
 			  (progn
 			    (just-one-space)
-			    (indent-to ind))
-			)))
+			    (indent-to ind)))))
 		(if (looking-at verilog-declaration-re-2-no-macro)
 		    (let ((p (match-end 0)))
 		      (set-marker m1 p)
@@ -5362,11 +5153,8 @@
 	    (if (or (null verilog-pred)
 		    (funcall verilog-pred match))
 		(setq verilog-all (cons match verilog-all)))))
-      (forward-line 1)
-      )
-    )
-  verilog-all
-  )
+      (forward-line 1)))
+  verilog-all)
 
 (defun verilog-type-completion ()
   "Calculate all possible completions for types."
@@ -5663,8 +5451,7 @@
 	    (goto-char pt)
 	    (beginning-of-line))
 	  pt)
-	(verilog-goto-defun-file label)
-	)))
+	(verilog-goto-defun-file label))))
 
 ;; Eliminate compile warning
 (eval-when-compile
@@ -5680,8 +5467,7 @@
 	(first 1)
 	(prevpos (point-min))
         (final-context-start (make-marker))
-	(regexp "\\(module\\s-+\\w+\\s-*(\\)\\|\\(\\w+\\s-+\\w+\\s-*(\\)")
-	)
+	(regexp "\\(module\\s-+\\w+\\s-*(\\)\\|\\(\\w+\\s-+\\w+\\s-*(\\)"))
     (with-output-to-temp-buffer "*Occur*"
       (save-excursion
 	(message (format "Searching for %s ..." regexp))
@@ -5854,8 +5640,7 @@
       (search-forward "<company>")
       (replace-match string t t)
       (search-backward "<description>")
-      (replace-match "" t t)
-      )))
+      (replace-match "" t t))))
 
 ;; verilog-header Uses the verilog-insert-date function
 
@@ -5994,8 +5779,7 @@
 	      sv-type    (verilog-sig-type sig)
 	      sv-multidim (verilog-sig-multidim sig)
 	      combo ""
-	      buswarn ""
-	      ))
+	      buswarn ""))
       ;; Extract bus details
       (setq bus (verilog-sig-bits sig))
       (cond ((and bus
@@ -6043,16 +5827,15 @@
 			      (if sv-highbit
 				  (concat "[" (int-to-string sv-highbit) ":"
 					  (int-to-string sv-lowbit) "]")))
-			       (concat sv-comment combo buswarn)
-			       sv-memory sv-enum sv-signed sv-type sv-multidim)
-			 out-list)
-		   sv-name nil)))
-      )
+			  (concat sv-comment combo buswarn)
+			  sv-memory sv-enum sv-signed sv-type sv-multidim)
+		    out-list)
+		   sv-name nil))))
     ;;
     out-list))
 
 (defun verilog-sig-tieoff (sig &optional no-width)
-  "Return tieoff expression for given SIGNAL, with appropriate width.
+  "Return tieoff expression for given SIG, with appropriate width.
 Ignore width if optional NO-WIDTH is set."
   (let* ((width (if no-width nil (verilog-sig-width sig))))
     (concat
@@ -6189,8 +5972,7 @@
 		      (forward-char 1)
 		      (when (< paren sig-paren)
 			(setq expect-signal nil))   ; ) that ends variables inside v2k arg list
-		      t)
-		     )))
+		      t))))
 	 ((looking-at "\\s-*\\(\\[[^]]+\\]\\)")
 	  (goto-char (match-end 0))
 	  (cond (newsig	; Memory, not just width.  Patch last signal added's memory (nth 3)
@@ -6272,12 +6054,15 @@
 	      (nreverse sigs-reg)
 	      (nreverse sigs-assign)
 	      (nreverse sigs-const)
-	      (nreverse sigs-gparam)
-	      ))))
-
-(defvar sigs-in)                        ; Prevent compile warning
-(defvar sigs-inout)                     ; Prevent compile warning
-(defvar sigs-out)                       ; Prevent compile warning
+	      (nreverse sigs-gparam)))))
+
+(eval-when-compile
+  ;; Prevent compile warnings; these are let's, not globals
+  ;; Do not remove the eval-when-compile
+  ;; - we want a error when we are debugging this code if they are refed.
+  (defvar sigs-in)
+  (defvar sigs-inout)
+  (defvar sigs-out))
 
 
 (defsubst verilog-modi-get-decls (modi)
@@ -6524,10 +6309,16 @@
 	     (end-pt (point)))
 	(eval-region beg-pt end-pt nil)))))
 
-;; These are passed in a let, not global
-(defvar got-sig)
-(defvar got-rvalue)
-(defvar uses-delayed)
+(eval-when-compile
+  ;; Prevent compile warnings; these are let's, not globals
+  ;; Do not remove the eval-when-compile
+  ;; - we want a error when we are debugging this code if they are refed.
+  (defvar sigs-in)
+  (defvar sigs-out)
+  (defvar got-sig)
+  (defvar got-rvalue)
+  (defvar uses-delayed)
+  (defvar vector-skip-list))
 
 (defun verilog-read-always-signals-recurse
   (exit-keywd rvalue ignore-next)
@@ -6653,8 +6444,7 @@
 	   (t
 	    (forward-char 1)))
 	  ;; End of non-comment token
-	  (setq last-keywd keywd)
-	  ))
+	  (setq last-keywd keywd)))
       (skip-syntax-forward " "))
     ;; Append the final pending signal
     (when got-sig
@@ -6700,8 +6490,7 @@
 		  (instant (match-string 2)))
 	      (if (not (member module verilog-keywords))
 		  (setq instants-list (cons (list module instant) instants-list)))))
-	(forward-line 1)
-	))
+	(forward-line 1)))
     instants-list))
 
 
@@ -6776,8 +6565,7 @@
 		     (t
 		      (error "%s: AUTO_TEMPLATE parsing error: %s"
 			     (verilog-point-text)
-			     (progn (looking-at ".*$") (match-string 0))))
-		     ))
+			     (progn (looking-at ".*$") (match-string 0))))))
 	     ;; Return
 	     (vector tpl-regexp
 		     (list tpl-sig-list tpl-wild-list)))
@@ -6799,8 +6587,7 @@
 	(let ((enumvar (intern (concat "venum-" enumname))))
 	  ;;(message "Define %s=%s" defname defvalue) (sleep-for 1)
 	  (make-variable-buffer-local enumvar)
-	  (add-to-list enumvar defname)))
-    ))
+	  (add-to-list enumvar defname)))))
 
 (defun verilog-read-defines (&optional filename recurse subcall)
   "Read `defines and parameters for the current file, or optional FILENAME.
@@ -6884,8 +6671,7 @@
 	  (while (looking-at "\\s-*,?\\s-*\\([a-zA-Z0-9_$]+\\)\\s-*=\\s-*\\([^;,]*\\),?\\s-*")
 	    (verilog-set-define (match-string-no-properties 1) (match-string-no-properties 2) origbuf enumname)
 	    (goto-char (match-end 0))
-	    (forward-comment 999))))
-      )))
+	    (forward-comment 999)))))))
 
 (defun verilog-read-includes ()
   "Read `includes for the current file.
@@ -6950,8 +6736,7 @@
 	  (or (member keywd verilog-keywords)
 	      (member keywd sigs-all)
 	      (setq sigs-all (cons keywd sigs-all))))
-	 (t (forward-char 1)))
-	)
+	 (t (forward-char 1))))
       ;; Return list
       sigs-all)))
 
@@ -7019,10 +6804,7 @@
        ((string-match "^[^-+]" arg)
 	(verilog-add-list-unique `verilog-library-files arg))
        ;; Default - ignore; no warning
-       )
-      )
-    )
-  )
+       ))))
 ;;(verilog-getopt (list "+libext+.a+.b" "+incdir+foodir" "+define+a+aval" "-f" "otherf" "-v" "library" "-y" "dir"))
 
 (defun verilog-getopt-file (filename)
@@ -7096,8 +6878,7 @@
   "Return true if SYMBOL is number-like."
   (or (string-match "^[0-9 \t:]+$" symbol)
       (string-match "^[---]*[0-9]+$" symbol)
-      (string-match "^[0-9 \t]+'s?[hdxbo][0-9a-fA-F_xz? \t]*$" symbol)
-      ))
+      (string-match "^[0-9 \t]+'s?[hdxbo][0-9a-fA-F_xz? \t]*$" symbol)))
 
 (defun verilog-symbol-detick (symbol wing-it)
   "Return a expanded SYMBOL name without any defines.
@@ -7185,13 +6966,11 @@
 	       (setq dirfile (expand-file-name (concat (car dirfiles) rest))
 		     dirfiles (cdr dirfiles))
 	       (if (file-directory-p dirfile)
-		   (setq dirlist (cons dirfile dirlist))))
-	     )
+		   (setq dirlist (cons dirfile dirlist)))))
 	    ;; Defaults
 	    (t
 	     (if (file-directory-p dirname)
-		 (setq dirlist (cons dirname dirlist))))
-	    ))
+		 (setq dirlist (cons dirname dirlist))))))
     dirlist))
 ;;(verilog-expand-dirnames (list "." ".." "nonexist" "../*" "/home/wsnyder/*/v"))
 
@@ -7295,13 +7074,11 @@
 					     "")
 					   "\n    Check the verilog-library-directories variable."
 					   "\n    I looked in (if not listed, doesn't exist):\n\t"
-					   (mapconcat 'concat orig-filenames "\n\t")))))
-		     )
+					   (mapconcat 'concat orig-filenames "\n\t"))))))
 	       (setq verilog-modi-lookup-last-mod module
 		     verilog-modi-lookup-last-current current
 		     verilog-modi-lookup-last-tick (buffer-modified-tick)))))
-    verilog-modi-lookup-last-modi
-    ))
+    verilog-modi-lookup-last-modi))
 
 (defsubst verilog-modi-name (modi)
   (aref modi 0))
@@ -7370,8 +7147,7 @@
 			       (buffer-modified-tick)
 			       (visited-file-modtime)
 			       func-returns)
-			 verilog-modi-cache-list)))
-	    ))
+			 verilog-modi-cache-list)))))
       ;;
       func-returns))
 
@@ -7483,7 +7259,7 @@
 	(funcall func))))
 
 (defun verilog-insert-one-definition (sig type indent-pt)
-  "Print out a definition for SIGNAL of the given TYPE,
+  "Print out a definition for SIG of the given TYPE,
 with appropriate INDENT-PT indentation."
   (indent-to indent-pt)
   (insert type)
@@ -7594,9 +7370,8 @@
 			     (string-to-number (match-string 2 range-exp)))))))
 	       ((string-match "^\\(.*\\)\\s *:\\s *\\(.*\\)\\s *$" range-exp)
 		(concat "(1+(" (match-string 1 range-exp) ")"
-			(if (equal "0" (match-string 2 range-exp)) 
-			    ;; Don't bother with -(0)
-			    ""
+			(if (equal "0" (match-string 2 range-exp))
+			    ""  ;; Don't bother with -(0)
 			  (concat "-(" (match-string 2 range-exp) ")"))
 			")"))
 	       (t nil)))))
@@ -7621,8 +7396,7 @@
       ;; End exists
       (end-of-line)
       (delete-region pt (point))
-      (forward-line 1))
-  ))
+      (forward-line 1))))
 
 (defun verilog-forward-close-paren ()
   "Find the close parenthesis that match the current point,
@@ -7897,8 +7671,7 @@
 	 (when (yes-or-no-p "AUTO statements not recomputed, do it now? ")
 	   (verilog-auto))
 	 ;; Don't ask again if didn't update
-	 (set (make-local-variable 'verilog-auto-update-tick) (buffer-modified-tick))
-	 ))
+	 (set (make-local-variable 'verilog-auto-update-tick) (buffer-modified-tick))))
   (when (not verilog-auto-star-save)
     (verilog-delete-auto-star-implicit))
   nil)	;; Always return nil -- we don't write the file ourselves
@@ -8008,13 +7781,11 @@
       (verilog-repair-close-comma)
       (unless (eq (char-before) ?/ )
 	(insert "\n"))
-      (indent-to verilog-indent-level-declaration)
-      )))
+      (indent-to verilog-indent-level-declaration))))
 
 (defun verilog-auto-inst-port-map (port-st)
   nil)
 
-(defvar vector-skip-list nil) ; Prevent compile warning
 (defvar vl-cell-type nil "See `verilog-auto-inst'.") ; Prevent compile warning
 (defvar vl-cell-name nil "See `verilog-auto-inst'.") ; Prevent compile warning
 (defvar vl-name  nil "See `verilog-auto-inst'.") ; Prevent compile warning
@@ -8025,7 +7796,8 @@
   "Print out a instantiation connection for this PORT-ST.
 Insert to INDENT-PT, use template TPL-LIST.
 @ are instantiation numbers, replaced with TPL-NUM.
-@\"(expression @)\" are evaluated, with @ as a variable."
+@\"(expression @)\" are evaluated, with @ as a variable.
+If FOR-STAR add comment it is a .* expansion."
   (let* ((port (verilog-sig-name port-st))
 	 (tpl-ass (or (assoc port (car tpl-list))
 		      (verilog-auto-inst-port-map port-st)))
@@ -8072,13 +7844,11 @@
 			     (prin1 (eval (car (read-from-string expr)))
 				    (lambda (ch) ())))))
 		     (if (numberp value) (setq value (number-to-string value)))
-		     value
-		     ))
+		     value))
 		 (substring tpl-net (match-end 0))))))
       ;; Replace @ and [] magic variables in final output
       (setq tpl-net (verilog-string-replace-matches "@" tpl-num nil nil tpl-net))
-      (setq tpl-net (verilog-string-replace-matches "\\[\\]" vl-bits nil nil tpl-net))
-      )
+      (setq tpl-net (verilog-string-replace-matches "\\[\\]" vl-bits nil nil tpl-net)))
     (indent-to indent-pt)
     (insert "." port)
     (indent-to verilog-auto-inst-column)
@@ -8462,9 +8232,7 @@
 		 (if (search-forward ")" nil t) ;; From user, moved up a line
 		     (delete-backward-char 1))
 		 (if (search-forward ";" nil t) ;; Don't error if user had syntax error and forgot it
-		     (delete-backward-char 1))
-		 )))
-	))))
+		     (delete-backward-char 1)))))))))
 
 (defun verilog-auto-inst-param ()
   "Expand AUTOINSTPARAM statements, as part of \\[verilog-auto].
@@ -8566,9 +8334,7 @@
 		 (search-forward "\n")	;; Added by inst-port
 		 (delete-backward-char 1)
 		 (if (search-forward ")" nil t) ;; From user, moved up a line
-		     (delete-backward-char 1))
-		 )))
-	))))
+		     (delete-backward-char 1)))))))))
 
 (defun verilog-auto-reg ()
   "Expand AUTOREG statements, as part of \\[verilog-auto].
@@ -8612,15 +8378,13 @@
 			      (verilog-modi-get-consts modi)
 			      (verilog-modi-get-gparams modi)
 			      (verilog-modi-get-sub-outputs modi)
-			      (verilog-modi-get-sub-inouts modi)
-			      ))))
+			      (verilog-modi-get-sub-inouts modi)))))
       (forward-line 1)
       (when sig-list
 	(verilog-insert-indent "// Beginning of automatic regs (for this module's undeclared outputs)\n")
 	(verilog-insert-definition sig-list "reg" indent-pt nil)
 	(verilog-modi-cache-add-regs modi sig-list)
-	(verilog-insert-indent "// End of automatics\n"))
-      )))
+	(verilog-insert-indent "// End of automatics\n")))))
 
 (defun verilog-auto-reg-input ()
   "Expand AUTOREGINPUT statements, as part of \\[verilog-auto].
@@ -8665,15 +8429,13 @@
 		      (verilog-signals-not-in
 		       (append (verilog-modi-get-sub-inputs modi)
 			       (verilog-modi-get-sub-inouts modi))
-		       (verilog-modi-get-signals modi)
-		       ))))
+		       (verilog-modi-get-signals modi)))))
       (forward-line 1)
       (when sig-list
 	(verilog-insert-indent "// Beginning of automatic reg inputs (for undeclared instantiated-module inputs)\n")
 	(verilog-insert-definition sig-list "reg" indent-pt nil)
 	(verilog-modi-cache-add-regs modi sig-list)
-	(verilog-insert-indent "// End of automatics\n"))
-      )))
+	(verilog-insert-indent "// End of automatics\n")))))
 
 (defun verilog-auto-wire ()
   "Expand AUTOWIRE statements, as part of \\[verilog-auto].
@@ -8726,8 +8488,7 @@
 		      (verilog-signals-not-in
 		       (append (verilog-modi-get-sub-outputs modi)
 			       (verilog-modi-get-sub-inouts modi))
-		       (verilog-modi-get-signals modi)
-		       ))))
+		       (verilog-modi-get-signals modi)))))
       (forward-line 1)
       (when sig-list
 	(verilog-insert-indent "// Beginning of automatic wires (for undeclared instantiated-module outputs)\n")
@@ -8739,8 +8500,7 @@
 	  (setq pnt (point))
 	  (verilog-pretty-declarations)
 	  (goto-char pnt)
-	  (verilog-pretty-expr "//")))
-      )))
+	  (verilog-pretty-expr "//"))))))
 
 (defun verilog-auto-output ()
   "Expand AUTOOUTPUT statements, as part of \\[verilog-auto].
@@ -8793,8 +8553,7 @@
 		      (append (verilog-modi-get-outputs modi)
 			      (verilog-modi-get-inouts modi)
 			      (verilog-modi-get-sub-inputs modi)
-			      (verilog-modi-get-sub-inouts modi)
-			      ))))
+			      (verilog-modi-get-sub-inouts modi)))))
       (setq sig-list (verilog-signals-not-matching-regexp
 		      sig-list verilog-auto-output-ignore-regexp))
       (forward-line 1)
@@ -8804,8 +8563,7 @@
 	(verilog-insert-definition sig-list "output" indent-pt v2k)
 	(verilog-modi-cache-add-outputs modi sig-list)
 	(verilog-insert-indent "// End of automatics\n"))
-      (when v2k (verilog-repair-close-comma))
-      )))
+      (when v2k (verilog-repair-close-comma)))))
 
 (defun verilog-auto-output-every ()
   "Expand AUTOOUTPUTEVERY statements, as part of \\[verilog-auto].
@@ -8847,8 +8605,7 @@
 	   (sig-list (verilog-signals-combine-bus
 		      (verilog-signals-not-in
 		       (verilog-modi-get-signals modi)
-		       (verilog-modi-get-ports modi)
-		       ))))
+		       (verilog-modi-get-ports modi)))))
       (forward-line 1)
       (when v2k (verilog-repair-open-comma))
       (when sig-list
@@ -8856,8 +8613,7 @@
 	(verilog-insert-definition sig-list "output" indent-pt v2k)
 	(verilog-modi-cache-add-outputs modi sig-list)
 	(verilog-insert-indent "// End of automatics\n"))
-      (when v2k (verilog-repair-close-comma))
-      )))
+      (when v2k (verilog-repair-close-comma)))))
 
 (defun verilog-auto-input ()
   "Expand AUTOINPUT statements, as part of \\[verilog-auto].
@@ -8913,8 +8669,7 @@
 			      (verilog-modi-get-consts modi)
 			      (verilog-modi-get-gparams modi)
 			      (verilog-modi-get-sub-outputs modi)
-			      (verilog-modi-get-sub-inouts modi)
-			      ))))
+			      (verilog-modi-get-sub-inouts modi)))))
       (setq sig-list (verilog-signals-not-matching-regexp
 		      sig-list verilog-auto-input-ignore-regexp))
       (forward-line 1)
@@ -8924,8 +8679,7 @@
 	(verilog-insert-definition sig-list "input" indent-pt v2k)
 	(verilog-modi-cache-add-inputs modi sig-list)
 	(verilog-insert-indent "// End of automatics\n"))
-      (when v2k (verilog-repair-close-comma))
-      )))
+      (when v2k (verilog-repair-close-comma)))))
 
 (defun verilog-auto-inout ()
   "Expand AUTOINOUT statements, as part of \\[verilog-auto].
@@ -8978,8 +8732,7 @@
 			      (verilog-modi-get-inouts modi)
 			      (verilog-modi-get-inputs modi)
 			      (verilog-modi-get-sub-inputs modi)
-			      (verilog-modi-get-sub-outputs modi)
-			      ))))
+			      (verilog-modi-get-sub-outputs modi)))))
       (setq sig-list (verilog-signals-not-matching-regexp
 		      sig-list verilog-auto-inout-ignore-regexp))
       (forward-line 1)
@@ -8989,8 +8742,7 @@
 	(verilog-insert-definition sig-list "inout" indent-pt v2k)
 	(verilog-modi-cache-add-inouts modi sig-list)
 	(verilog-insert-indent "// End of automatics\n"))
-      (when v2k (verilog-repair-close-comma))
-      )))
+      (when v2k (verilog-repair-close-comma)))))
 
 (defun verilog-auto-inout-module ()
   "Expand AUTOINOUTMODULE statements, as part of \\[verilog-auto].
@@ -9062,8 +8814,7 @@
 	    (verilog-modi-cache-add-outputs modi sig-list-o)
 	    (verilog-modi-cache-add-inouts modi sig-list-io)
 	    (verilog-insert-indent "// End of automatics\n"))
-	  (when v2k (verilog-repair-close-comma))
-	  )))))
+	  (when v2k (verilog-repair-close-comma)))))))
 
 (defun verilog-auto-sense-sigs (modi presense-sigs)
   "Return list of signals for current AUTOSENSE block."
@@ -9164,8 +8915,7 @@
 	      (not-first (insert " or ")))
 	(insert (verilog-sig-name (car sig-list)))
 	(setq sig-list (cdr sig-list)
-	      not-first t))
-      )))
+	      not-first t)))))
 
 (defun verilog-auto-reset ()
   "Expand AUTORESET statements, as part of \\[verilog-auto].
@@ -9260,8 +9010,7 @@
 		    ";\n")
 	    (indent-to indent-pt)
 	    (setq sig-list (cdr sig-list))))
-	(insert "// End of automatics"))
-      )))
+	(insert "// End of automatics")))))
 
 (defun verilog-auto-tieoff ()
   "Expand AUTOTIEOFF statements, as part of \\[verilog-auto].
@@ -9316,8 +9065,7 @@
 			      (verilog-modi-get-consts modi)
 			      (verilog-modi-get-gparams modi)
 			      (verilog-modi-get-sub-outputs modi)
-			      (verilog-modi-get-sub-inouts modi)
-			      ))))
+			      (verilog-modi-get-sub-inouts modi)))))
       (when sig-list
 	(forward-line 1)
 	(verilog-insert-indent "// Beginning of automatic tieoffs (for this module's unterminated outputs)\n")
@@ -9330,8 +9078,7 @@
 	    (insert "= " (verilog-sig-tieoff sig)
 		    ";\n")
 	    (setq sig-list (cdr sig-list))))
-	(verilog-insert-indent "// End of automatics\n")
-	))))
+	(verilog-insert-indent "// End of automatics\n")))))
 
 (defun verilog-auto-unused ()
   "Expand AUTOUNUSED statements, as part of \\[verilog-auto].
@@ -9395,8 +9142,7 @@
 		      (append (verilog-modi-get-inputs modi)
 			      (verilog-modi-get-inouts modi))
 		      (append (verilog-modi-get-sub-inputs modi)
-			      (verilog-modi-get-sub-inouts modi)
-			      ))))
+			      (verilog-modi-get-sub-inouts modi)))))
       (setq sig-list (verilog-signals-not-matching-regexp
 		      sig-list verilog-auto-unused-ignore-regexp))
       (when sig-list
@@ -9408,8 +9154,7 @@
 	    (indent-to indent-pt)
 	    (insert (verilog-sig-name sig) ",\n")
 	    (setq sig-list (cdr sig-list))))
-	(verilog-insert-indent "// End of automatics\n")
-	))))
+	(verilog-insert-indent "// End of automatics\n")))))
 
 (defun verilog-enum-ascii (signm elim-regexp)
   "Convert a enum name SIGNM to a ascii string for insertion.
@@ -9543,8 +9288,7 @@
       (verilog-insert-indent "endcase\n")
       (setq indent-pt (- indent-pt verilog-indent-level))
       (verilog-insert-indent "end\n"
-			     "// End of automatics\n")
-      )))
+			     "// End of automatics\n"))))
 
 (defun verilog-auto-templated-rel ()
   "Replace Templated relative line numbers with absolute line numbers.
@@ -9694,8 +9438,7 @@
 	   ;; Must be after all inputs outputs are generated
 	   (verilog-auto-search-do "/*AUTOARG*/" 'verilog-auto-arg)
 	   ;; Fix line numbers (comments only)
-	   (verilog-auto-templated-rel)
-	   )
+	   (verilog-auto-templated-rel))
 	  ;;
 	  (run-hooks 'verilog-auto-hook)
 	  ;;
@@ -9709,14 +9452,13 @@
       ;; Unwind forms
       (progn
 	;; Restore font-lock
-	(when fontlocked (font-lock-mode t)))
-      )))
+	(when fontlocked (font-lock-mode t))))))
 
 
 ;;
 ;; Skeleton based code insertion
 ;;
-(defvar verilog-template-map 
+(defvar verilog-template-map
   (let ((map (make-sparse-keymap)))
     (define-key map "a" 'verilog-sk-always)
     (define-key map "b" 'verilog-sk-begin)
@@ -9985,16 +9727,14 @@
 (defun verilog-sk-define-signal ()
   "Insert a definition of signal under point at top of module."
   (interactive "*")
-  (let* (
-	 (sig-re "[a-zA-Z0-9_]*")
+  (let* ((sig-re "[a-zA-Z0-9_]*")
 	 (v1 (buffer-substring
 	       (save-excursion
 		 (skip-chars-backward sig-re)
 		 (point))
 	       (save-excursion
 		 (skip-chars-forward sig-re)
-		 (point))))
-	 )
+		 (point)))))
     (if (not (member v1 verilog-keywords))
 	(save-excursion
 	  (setq verilog-sk-signal v1)
@@ -10003,10 +9743,7 @@
 	  (verilog-forward-syntactic-ws)
 	  (verilog-sk-def-reg)
 	  (message "signal at point is %s" v1))
-      (message "object at point (%s) is a keyword" v1))
-    )
-  )
-
+      (message "object at point (%s) is a keyword" v1))))
 
 (define-skeleton verilog-sk-wire
   "Insert a wire definition."
@@ -10109,7 +9846,7 @@
   "^`include\\s-+\"\\([^\n\"]*\\)\""
   "Regexp that matches the include file.")
 
-(defvar verilog-mode-mouse-map 
+(defvar verilog-mode-mouse-map
   (let ((map (make-sparse-keymap))) ; as described in info pages, make a map
     (set-keymap-parent map verilog-mode-map)
     ;; mouse button bindings
@@ -10189,8 +9926,7 @@
 	  (progn
 	    (message
 	     "File '%s' isn't readable, use shift-mouse2 to paste in this field"
-	     (match-string 1))))
-      )))
+	     (match-string 1)))))))
 
 ;; ffap isn't useable for verilog mode. It uses library paths.
 ;; so define this function to do more or less the same as ffap
@@ -10208,8 +9944,7 @@
 	     (file-readable-p (car (verilog-library-filenames
 				    (match-string 1) (buffer-file-name)))))
 	    (find-file (car (verilog-library-filenames
-			     (match-string 1) (buffer-file-name))))))
-      ))
+			     (match-string 1) (buffer-file-name))))))))
 
 
 ;;
@@ -10230,6 +9965,7 @@
     (princ "\n")))
 
 (autoload 'reporter-submit-bug-report "reporter")
+(defvar reporter-prompt-for-summary-p)
 
 (defun verilog-submit-bug-report ()
   "Submit via mail a bug report on verilog-mode.el."
--- a/lisp/subr.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/subr.el	Tue Jan 22 23:53:46 2008 +0000
@@ -1860,6 +1860,10 @@
   (let ((handle (make-symbol "--change-group-handle--"))
 	(success (make-symbol "--change-group-success--")))
     `(let ((,handle (prepare-change-group))
+	   ;; Don't truncate any undo data in the middle of this.
+	   (undo-outer-limit nil)
+	   (undo-limit most-positive-fixnum)
+	   (undo-strong-limit most-positive-fixnum)
 	   (,success nil))
        (unwind-protect
 	   (progn
--- a/lisp/url/ChangeLog	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/url/ChangeLog	Tue Jan 22 23:53:46 2008 +0000
@@ -1,3 +1,8 @@
+2008-01-21  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* url-handlers.el (unhandled-file-name-directory): Add handler.
+	(url-handler-unhandled-file-name-directory): New fun.
+
 2008-01-07  Michael Albinus  <michael.albinus@gmx.de>
 
 	* url-handlers.el (url-file-handler): Autoload.
--- a/lisp/url/url-handlers.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/url/url-handlers.el	Tue Jan 22 23:53:46 2008 +0000
@@ -150,6 +150,7 @@
 (put 'file-name-absolute-p 'url-file-handlers (lambda (&rest ignored) t))
 (put 'expand-file-name 'url-file-handlers 'url-handler-expand-file-name)
 (put 'directory-file-name 'url-file-handlers 'url-handler-directory-file-name)
+(put 'unhandled-file-name-directory 'url-file-handlers 'url-handler-unhandled-file-name-directory)
 ;; (put 'file-name-as-directory 'url-file-handlers 'url-handler-file-name-as-directory)
 
 ;; These are operations that we do not support yet (DAV!!!)
@@ -181,6 +182,13 @@
   (if (string-match "//\\'" dir) dir
     (url-run-real-handler 'directory-file-name (list dir))))
 
+(defun url-handler-unhandled-file-name-directory (filename)
+  ;; Copied from tramp.el.  This is used as the cwd for subprocesses:
+  ;; without it running call-process or start-process in a URL directory
+  ;; signals an error.
+  ;; FIXME: we can do better if `filename' is a "file://" URL.
+  (expand-file-name "~/"))
+
 ;; The actual implementation
 ;;;###autoload
 (defun url-copy-file (url newname &optional ok-if-already-exists keep-time)
--- a/lisp/vc-arch.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/vc-arch.el	Tue Jan 22 23:53:46 2008 +0000
@@ -347,9 +347,11 @@
   (save-excursion
     (let ((rej (concat buffer-file-name ".rej")))
       (when (and buffer-file-name (vc-arch-diff3-rej-p rej))
-	(if (not (re-search-forward "^<<<<<<< " nil t))
-	    ;; The .rej file is obsolete.
-	    (condition-case nil (delete-file rej) (error nil)))))))
+	(unless (re-search-forward "^<<<<<<< " nil t)
+	  ;; The .rej file is obsolete.
+	  (condition-case nil (delete-file rej) (error nil))
+	  ;; Remove the hook so that it is not called multiple times.
+	  (remove-hook 'after-save-hook 'vc-arch-delete-rej-if-obsolete t))))))
 
 (defun vc-arch-find-file-hook ()
   (let ((rej (concat buffer-file-name ".rej")))
--- a/lisp/vc-hg.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/vc-hg.el	Tue Jan 22 23:53:46 2008 +0000
@@ -316,8 +316,7 @@
 	    (if oldvers
 		(if newvers
 		    (list "-r" oldvers "-r" newvers)
-		  (list "-r" oldvers))
-	      (list ""))))))
+		  (list "-r" oldvers)))))))
 
 (defun vc-hg-revision-table (files)
   (let ((default-directory (file-name-directory (car files))))
--- a/lisp/vc-svn.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/vc-svn.el	Tue Jan 22 23:53:46 2008 +0000
@@ -567,8 +567,10 @@
   "Call \"svn resolved\" if the conflict markers have been removed."
   (save-excursion
     (goto-char (point-min))
-    (if (not (re-search-forward "^<<<<<<< " nil t))
-        (vc-svn-command nil 0 buffer-file-name "resolved"))))
+    (unless (re-search-forward "^<<<<<<< " nil t)
+      (vc-svn-command nil 0 buffer-file-name "resolved")
+      ;; Remove the hook so that it is not called multiple times.
+      (remove-hook 'after-save-hook 'vc-svn-resolve-when-done t))))
 
 ;; Inspired by vc-arch-find-file-hook.
 (defun vc-svn-find-file-hook ()
--- a/lisp/view.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/view.el	Tue Jan 22 23:53:46 2008 +0000
@@ -243,6 +243,16 @@
 
 ;;; Commands that enter or exit view mode.
 
+;; This is used when view mode is exited, to make sure we don't try to
+;; kill a buffer modified by the user.  A buffer in view mode can
+;; become modified if the user types C-x C-q, edits the buffer, then
+;; types C-x C-q again to return to view mode.
+(defun kill-buffer-if-not-modified (buf)
+  "Like `kill-buffer', but does nothing if the buffer is modified."
+  (let ((buf (or (bufferp buf) (get-buffer buf))))
+    (and buf (not (buffer-modified-p buf))
+	 (kill-buffer buf))))
+
 ;;;###autoload
 (defun view-file (file)
   "View FILE in View mode, returning to previous buffer when done.
@@ -263,41 +273,50 @@
 	(progn
 	  (switch-to-buffer buffer)
 	  (message "Not using View mode because the major mode is special"))
-      (view-buffer buffer (and (not had-a-buf) 'kill-buffer)))))
+      (view-buffer buffer (and (not had-a-buf) 'kill-buffer-if-not-modified)))))
 
 ;;;###autoload
 (defun view-file-other-window (file)
   "View FILE in View mode in another window.
-Return that window to its previous buffer when done.  Emacs commands
-editing the buffer contents are not available; instead, a special set of
-commands (mostly letters and punctuation) are defined for moving around
-in the buffer.
+When done, return that window to its previous buffer, and kill the
+buffer visiting FILE if unmodified and if it wasn't visited before.
+
+Emacs commands editing the buffer contents are not available; instead,
+a special set of commands (mostly letters and punctuation)
+are defined for moving around in the buffer.
 Space scrolls forward, Delete scrolls backward.
 For a list of all View commands, type H or h while viewing.
 
 This command runs the normal hook `view-mode-hook'."
   (interactive "fIn other window view file: ")
   (unless (file-exists-p file) (error "%s does not exist" file))
-  (let ((had-a-buf (get-file-buffer file)))
-    (view-buffer-other-window (find-file-noselect file) nil
-			      (and (not had-a-buf) 'kill-buffer))))
+  (let ((had-a-buf (get-file-buffer file))
+	(buf-to-view (find-file-noselect file)))
+    (view-buffer-other-window buf-to-view nil
+			      (and (not had-a-buf)
+				   'kill-buffer-if-not-modified))))
 
 ;;;###autoload
 (defun view-file-other-frame (file)
   "View FILE in View mode in another frame.
-Maybe delete other frame and/or return to previous buffer when done.
-Emacs commands editing the buffer contents are not available; instead, a
-special set of commands (mostly letters and punctuation) are defined for
-moving around in the buffer.
+When done, kill the buffer visiting FILE if unmodified and if it wasn't
+visited before; also, maybe delete other frame and/or return to previous
+buffer.
+
+Emacs commands editing the buffer contents are not available; instead,
+a special set of commands (mostly letters and punctuation)
+are defined for moving around in the buffer.
 Space scrolls forward, Delete scrolls backward.
 For a list of all View commands, type H or h while viewing.
 
 This command runs the normal hook `view-mode-hook'."
   (interactive "fIn other frame view file: ")
   (unless (file-exists-p file) (error "%s does not exist" file))
-  (let ((had-a-buf (get-file-buffer file)))
-    (view-buffer-other-frame (find-file-noselect file) nil
-			     (and (not had-a-buf) 'kill-buffer))))
+  (let ((had-a-buf (get-file-buffer file))
+	(buf-to-view (find-file-noselect file)))
+    (view-buffer-other-frame buf-to-view nil
+			     (and (not had-a-buf)
+				  'kill-buffer-if-not-modified))))
 
 
 ;;;###autoload
--- a/lisp/whitespace.el	Tue Jan 22 15:44:14 2008 +0000
+++ b/lisp/whitespace.el	Tue Jan 22 23:53:46 2008 +0000
@@ -159,21 +159,21 @@
 
 (defcustom whitespace-check-leading-whitespace t
   "Flag to check leading whitespace.  This is the global for the system.
-It can be overriden by setting a buffer local variable
+It can be overridden by setting a buffer local variable
 `whitespace-check-buffer-leading'."
   :type 'boolean
   :group 'whitespace)
 
 (defcustom whitespace-check-trailing-whitespace t
   "Flag to check trailing whitespace.  This is the global for the system.
-It can be overriden by setting a buffer local variable
+It can be overridden by setting a buffer local variable
 `whitespace-check-buffer-trailing'."
   :type 'boolean
   :group 'whitespace)
 
 (defcustom whitespace-check-spacetab-whitespace t
   "Flag to check space followed by a TAB.  This is the global for the system.
-It can be overriden by setting a buffer local variable
+It can be overridden by setting a buffer local variable
 `whitespace-check-buffer-spacetab'."
   :type 'boolean
   :group 'whitespace)
@@ -185,7 +185,7 @@
 
 (defcustom whitespace-check-indent-whitespace indent-tabs-mode
   "Flag to check indentation whitespace.  This is the global for the system.
-It can be overriden by setting a buffer local variable
+It can be overridden by setting a buffer local variable
 `whitespace-check-buffer-indent'."
   :type 'boolean
   :group 'whitespace)
@@ -198,7 +198,7 @@
 
 (defcustom whitespace-check-ateol-whitespace t
   "Flag to check end-of-line whitespace.  This is the global for the system.
-It can be overriden by setting a buffer local variable
+It can be overridden by setting a buffer local variable
 `whitespace-check-buffer-ateol'."
   :type 'boolean
   :group 'whitespace)
--- a/nt/ChangeLog	Tue Jan 22 15:44:14 2008 +0000
+++ b/nt/ChangeLog	Tue Jan 22 23:53:46 2008 +0000
@@ -1,3 +1,8 @@
+2008-01-20  Jason Rumney  <jasonr@gnu.org>
+
+	* gmake.defs (CYGWIN) [USING_SH]: Disable mapping of file
+	permissions to NTFS ACLs.
+
 2007-11-01  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
 
 	* config.nt: Remove HAVE_X11R5.
--- a/nt/gmake.defs	Tue Jan 22 15:44:14 2008 +0000
+++ b/nt/gmake.defs	Tue Jan 22 23:53:46 2008 +0000
@@ -99,6 +99,16 @@
 ifeq "$(sh_output)" ""
 NEW_CYGWIN = 1
 endif
+
+# By default, newer versions of Cygwin mess with NTFS ACLs in an
+# attempt to emulate traditional posix file permissions. This can
+# cause bad effects, such as .exe files that are missing the
+# FILE_EXECUTE/FILE_GENERIC_EXECUTE permissions when they are created
+# with Cygwin commands that don't expect to be creating executable
+# files. Then when we later use a non-Cygwin program to create the
+# real .exe, the previous Cygwin defined ACL sticks.
+CYGWIN=nontsec
+export CYGWIN
 endif
 
 ALL_DEPS	= $^
--- a/src/ChangeLog	Tue Jan 22 15:44:14 2008 +0000
+++ b/src/ChangeLog	Tue Jan 22 23:53:46 2008 +0000
@@ -1,3 +1,28 @@
+2008-01-21  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
+
+	* macterm.c (x_scroll_bar_create): Initialize bar->redraw_needed_p.
+	(XTset_vertical_scroll_bar): Redraw scroll bar if bar->redraw_needed_p
+	is set even without positional changes.
+	(x_scroll_bar_clear): Set bar->redraw_needed_p.
+
+	* macterm.h (struct scroll_bar): New member `redraw_needed_p'.
+
+2008-01-17  Jason Rumney  <jasonr@gnu.org>
+
+	* xterm.c (handle_one_xevent): Revert to counting chars not bytes.
+
+	* w32term.c (w32_read_socket) <WM_CHAR>: Decode characters outside
+	the unicode range available in MULE by locale-coding-system.
+	Improve dbcs lead byte detection.  Set event timestamp and modifiers
+	earlier.
+
+2008-01-11  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
+
+	* mac.c (mac_emacs_pid) [MAC_OSX]: New variable.
+	[MAC_OSX] (init_mac_osx_environment): Initialize it.
+	[MAC_OSX] (mac_try_close_socket) [SELECT_USE_CFSOCKET]:	Return 0
+	when used on child processes.
+
 2008-01-21  Michael Albinus  <michael.albinus@gmx.de>
 
 	* dbusbind.el (Fdbus_method_return_internal): Renamed from
--- a/src/fns.c	Tue Jan 22 15:44:14 2008 +0000
+++ b/src/fns.c	Tue Jan 22 23:53:46 2008 +0000
@@ -5829,9 +5829,10 @@
 
   DEFVAR_BOOL ("use-file-dialog", &use_file_dialog,
     doc: /* *Non-nil means mouse commands use a file dialog to ask for files.
-This applies to commands from menus and tool bar buttons.  The value of
-`use-dialog-box' takes precedence over this variable, so a file dialog is only
-used if both `use-dialog-box' and this variable are non-nil.  */);
+This applies to commands from menus and tool bar buttons even when
+they are initiated from the keyboard.  The value of `use-dialog-box'
+takes precedence over this variable, so a file dialog is only used if
+both `use-dialog-box' and this variable are non-nil.  */);
   use_file_dialog = 1;
 
   defsubr (&Sidentity);
--- a/src/mac.c	Tue Jan 22 15:44:14 2008 +0000
+++ b/src/mac.c	Tue Jan 22 23:53:46 2008 +0000
@@ -5008,6 +5008,9 @@
    sys_select.  */
 static CFMutableDictionaryRef cfsockets_for_select;
 
+/* Process ID of Emacs.  */
+static pid_t mac_emacs_pid;
+
 static void
 socket_callback (s, type, address, data, info)
      CFSocketRef s;
@@ -5103,7 +5106,7 @@
      int fd;
 {
 #if SELECT_USE_CFSOCKET
-  if (cfsockets_for_select)
+  if (getpid () == mac_emacs_pid && cfsockets_for_select)
     {
       void *key = (void *) fd;
       CFSocketRef socket =
@@ -5339,6 +5342,8 @@
   char *p, *q;
   struct stat st;
 
+  mac_emacs_pid = getpid ();
+
   /* Initialize locale related variables.  */
   mac_system_script_code =
     (ScriptCode) GetScriptManagerVariable (smSysScript);
--- a/src/macterm.c	Tue Jan 22 15:44:14 2008 +0000
+++ b/src/macterm.c	Tue Jan 22 23:53:46 2008 +0000
@@ -5069,6 +5069,7 @@
 #ifdef MAC_OSX
   bar->fringe_extended_p = Qnil;
 #endif
+  bar->redraw_needed_p = Qnil;
 #ifdef USE_TOOLKIT_SCROLL_BARS
   bar->track_top = Qnil;
   bar->track_height = Qnil;
@@ -5285,14 +5286,24 @@
       BLOCK_INPUT;
 
       /* If already correctly positioned, do nothing.  */
-      if (!(XINT (bar->left) == sb_left
-	    && XINT (bar->top) == top
-	    && XINT (bar->width) == sb_width
-	    && XINT (bar->height) == height
+      if (XINT (bar->left) == sb_left
+	  && XINT (bar->top) == top
+	  && XINT (bar->width) == sb_width
+	  && XINT (bar->height) == height
 #ifdef MAC_OSX
-	    && !NILP (bar->fringe_extended_p) == fringe_extended_p
-#endif
-	    ))
+	  && !NILP (bar->fringe_extended_p) == fringe_extended_p
+#endif
+	  )
+	{
+	  if (!NILP (bar->redraw_needed_p))
+	    {
+#if USE_CG_DRAWING
+	      mac_prepare_for_quickdraw (f);
+#endif
+	      Draw1Control (SCROLL_BAR_CONTROL_HANDLE (bar));
+	    }
+	}
+      else
 	{
 	  /* Since toolkit scroll bars are smaller than the space reserved
 	     for them on the frame, we have to clear "under" them.  */
@@ -5334,6 +5345,8 @@
   bar->fringe_extended_p = fringe_extended_p ? Qt : Qnil;
 #endif
 
+  bar->redraw_needed_p = Qnil;
+
 #ifdef USE_TOOLKIT_SCROLL_BARS
   if (NILP (bar->track_top))
     {
@@ -5691,8 +5704,15 @@
 x_scroll_bar_clear (f)
      FRAME_PTR f;
 {
-  XTcondemn_scroll_bars (f);
-  XTjudge_scroll_bars (f);
+  Lisp_Object bar;
+
+  /* We can have scroll bars even if this is 0,
+     if we just turned off scroll bar mode.
+     But in that case we should not clear them.  */
+  if (FRAME_HAS_VERTICAL_SCROLL_BARS (f))
+    for (bar = FRAME_SCROLL_BARS (f); VECTORP (bar);
+	 bar = XSCROLL_BAR (bar)->next)
+      XSCROLL_BAR (bar)->redraw_needed_p = Qt;
 }
 
 
--- a/src/macterm.h	Tue Jan 22 15:44:14 2008 +0000
+++ b/src/macterm.h	Tue Jan 22 23:53:46 2008 +0000
@@ -457,6 +457,9 @@
   Lisp_Object fringe_extended_p;
 #endif
 
+  /* t if redraw needed in the next XTset_vertical_scroll_bar call.  */
+  Lisp_Object redraw_needed_p;
+
 #ifdef USE_TOOLKIT_SCROLL_BARS
   /* The position and size of the scroll bar handle track area in
      pixels, relative to the frame.  */
--- a/src/w32term.c	Tue Jan 22 15:44:14 2008 +0000
+++ b/src/w32term.c	Tue Jan 22 23:53:46 2008 +0000
@@ -4332,6 +4332,10 @@
 		temp_index = 0;
 	      temp_buffer[temp_index++] = msg.msg.wParam;
 
+              inev.modifiers = msg.dwModifiers;
+              XSETFRAME (inev.frame_or_window, f);
+              inev.timestamp = msg.msg.time;
+
               if (msg.msg.wParam < 128 && !dbcs_lead)
                 {
                   inev.kind = ASCII_KEYSTROKE_EVENT;
@@ -4340,20 +4344,14 @@
               else if (msg.msg.wParam < 256)
                 {
                   wchar_t code;
-
+                  char dbcs[2];
                   inev.kind = MULTIBYTE_CHAR_KEYSTROKE_EVENT;
-
-                  if (IsDBCSLeadByteEx(CP_ACP, (BYTE) msg.msg.wParam))
+                  dbcs[0] = 0;
+                  dbcs[1] = (char) msg.msg.wParam;
+
+                  if (dbcs_lead)
                     {
-                      dbcs_lead = (char) msg.msg.wParam;
-                      inev.kind = NO_EVENT;
-                      break;
-                    }
-                  else if (dbcs_lead)
-                    {
-                      char dbcs[2];
                       dbcs[0] = dbcs_lead;
-                      dbcs[1] = (char) msg.msg.wParam;
                       dbcs_lead = 0;
                       if (!MultiByteToWideChar(CP_ACP, 0, dbcs, 2, &code, 1))
                         {
@@ -4364,14 +4362,19 @@
                           break;
                         }
                     }
+                  else if (IsDBCSLeadByteEx(CP_ACP, (BYTE) msg.msg.wParam))
+                    {
+                      dbcs_lead = (char) msg.msg.wParam;
+                      inev.kind = NO_EVENT;
+                      break;
+                    }
                   else
                     {
-                      char single_byte = (char) msg.msg.wParam;
-                      if (!MultiByteToWideChar(CP_ACP, 0, &single_byte, 1,
+                      if (!MultiByteToWideChar(CP_ACP, 0, &dbcs[1], 1,
                                                &code, 1))
                         {
                           /* What to do with garbage? */
-                          DebPrint (("Invalid character: %d\n", single_byte));
+                          DebPrint (("Invalid character: %d\n", dbcs[1]));
                           inev.kind = NO_EVENT;
                           break;
                         }
@@ -4397,17 +4400,67 @@
                           charset_id = charset_mule_unicode_0100_24ff;
                           code -= 0x100;
                         }
-                      else if (code < 0xE000)
+                      else if (code < 0x3400)
                         {
                           charset_id = charset_mule_unicode_2500_33ff;
                           code -= 0x2500;
                         }
-                      else
+                      else if (code >= 0xE000)
                         {
                           charset_id = charset_mule_unicode_e000_ffff;
                           code -= 0xE000;
                         }
-
+                      else
+                        {
+                          /* Not in the unicode range that we can handle in
+                             Emacs-22, so decode the original character
+                             using the locale  */
+                          int nbytes, nchars, require, i, len;
+                          unsigned char *dest;
+                          struct coding_system coding;
+
+                          if (dbcs[0] == 0)
+                            {
+                              nbytes = 1;
+                              dbcs[0] = dbcs[1];
+                            }
+                          else
+                            nbytes = 2;
+
+                          setup_coding_system (Vlocale_coding_system, &coding);
+                          coding.src_multibyte = 0;
+                          coding.dst_multibyte = 1;
+                          coding.composing = COMPOSITION_DISABLED;
+                          require = decoding_buffer_size (&coding, nbytes);
+                          dest = (unsigned char *) alloca (require);
+                          coding.mode |= CODING_MODE_LAST_BLOCK;
+
+                          decode_coding (&coding, dbcs, dest, nbytes, require);
+                          nbytes = coding.produced;
+                          nchars = coding.produced_char;
+
+                          for (i = 0; i < nbytes; i += len)
+                            {
+                              if (nchars == nbytes)
+                                {
+                                  inev.code = dest[i];
+                                  len = 1;
+                                }
+                              else
+                                inev.code = STRING_CHAR_AND_LENGTH (dest + i,
+                                                                    nbytes - 1,
+                                                                    len);
+                              inev.kind = (SINGLE_BYTE_CHAR_P (inev.code)
+                                           ? ASCII_KEYSTROKE_EVENT
+                                           : MULTIBYTE_CHAR_KEYSTROKE_EVENT);
+                              kbd_buffer_store_event_hold (&inev, hold_quit);
+                              count++;
+                            }
+                          inev.kind = NO_EVENT; /* Already handled */
+                          break;
+                        }
+
+                      /* Unicode characters from above.  */
                       c1 = (code / 96) + 32;
                       c2 = (code % 96) + 32;
                       inev.code = MAKE_CHAR (charset_id, c1, c2);
@@ -4421,9 +4474,6 @@
                   inev.kind = NO_EVENT;
                   break;
                 }
-	      inev.modifiers = msg.dwModifiers;
-	      XSETFRAME (inev.frame_or_window, f);
-	      inev.timestamp = msg.msg.time;
 	    }
 	  break;
 
--- a/src/xterm.c	Tue Jan 22 15:44:14 2008 +0000
+++ b/src/xterm.c	Tue Jan 22 23:53:46 2008 +0000
@@ -6558,9 +6558,7 @@
 		  }
 	      }
 
-	    /* Previous code updated count by nchars rather than nbytes,
-	       but that seems bogus to me.  ++kfs  */
-	    count += nbytes;
+	    count += nchars;
 
 	    inev.ie.kind = NO_EVENT;  /* Already stored above.  */
 
@@ -7057,7 +7055,9 @@
    We return as soon as there are no more events to be read.
 
    We return the number of characters stored into the buffer,
-   thus pretending to be `read'.
+   thus pretending to be `read' (except the characters we store
+   in the keyboard buffer can be multibyte, so are not necessarily
+   C chars).
 
    EXPECTED is nonzero if the caller knows input is available.  */