]> code.delx.au - gnu-emacs/blobdiff - src/abbrev.c
(x-keysym-table, x-selection-timeout, x-session-id, x-session-previous-id):
[gnu-emacs] / src / abbrev.c
index 37ab640ee43da07bd8d7157c43c3c8085a84bd1e..84054892910d274ea63d431e40df27e2440b44d1 100644 (file)
@@ -1,6 +1,6 @@
 /* Primitives for word-abbrev mode.
-   Copyright (C) 1985, 1986, 1993, 1996, 1998, 2001,02,03,04
-   Free Software Foundation, Inc.
+   Copyright (C) 1985, 1986, 1993, 1996, 1998, 2001, 2002, 2003, 2004,
+                 2005 Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
@@ -16,8 +16,8 @@ GNU General Public License for more details.
 
 You should have received a copy of the GNU General Public License
 along with GNU Emacs; see the file COPYING.  If not, write to
-the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA.  */
+the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+Boston, MA 02110-1301, USA.  */
 
 
 #include <config.h>
@@ -248,6 +248,8 @@ Returns the abbrev symbol, if expansion took place.  */)
 
   value = Qnil;
 
+  Frun_hooks (1, &Qpre_abbrev_expand_hook);
+
   wordstart = 0;
   if (!(BUFFERP (Vabbrev_start_location_buffer)
        && XBUFFER (Vabbrev_start_location_buffer) == current_buffer))
@@ -324,8 +326,6 @@ Returns the abbrev symbol, if expansion took place.  */)
   if (INTEGERP (sym) || NILP (SYMBOL_VALUE (sym)))
     return value;
 
-  Frun_hooks (1, &Qpre_abbrev_expand_hook);
-
   if (INTERACTIVE && !EQ (minibuf_window, selected_window))
     {
       /* Add an undo boundary, in case we are doing this for
@@ -442,7 +442,7 @@ is not undone.  */)
 
       val = SYMBOL_VALUE (Vlast_abbrev);
       if (!STRINGP (val))
-       error ("value of abbrev-symbol must be a string");
+       error ("Value of `abbrev-symbol' must be a string");
       zv_before = ZV;
       del_range_byte (PT_BYTE, PT_BYTE + SBYTES (val), 1);
       /* Don't inherit properties here; just copy from old contents.  */