From ee8caabbade460590867da42cc0b2861163cedf7 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 11 Sep 1992 23:34:08 +0000 Subject: [PATCH] (internal_self_insert): Assume Fexpand_abbrev expanded something if it incremented MODIFF. --- src/cmds.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/cmds.c b/src/cmds.c index 691a60f5cc0..c8e9bfd76ec 100644 --- a/src/cmds.c +++ b/src/cmds.c @@ -290,11 +290,12 @@ internal_self_insert (c1, noautofill) && NILP (current_buffer->read_only) && point > BEGV && SYNTAX (FETCH_CHAR (point - 1)) == Sword) { + int modiff = MODIFF; Fexpand_abbrev (); /* We can't trust the value of Fexpand_abbrev, - but if the buffer is now changed, this is "hairy" - and not suitable for direct output. */ - if (MODIFF <= current_buffer->save_modified) + but if Fexpand_abbrev changed the buffer, + assume it expanded something. */ + if (MODIFF != modiff) hairy = 1; } if ((c == ' ' || c == '\n')