changeset 44582:aca4f7ef2d56

(sgml-parse-tag-backward): Fix to work at beginning of buffer.
author Mike Williams <mdub@bigfoot.com>
date Sun, 14 Apr 2002 12:49:39 +0000
parents ab6889b1c705
children 09bdb53f0839
files lisp/textmodes/sgml-mode.el
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/textmodes/sgml-mode.el	Sun Apr 14 08:18:02 2002 +0000
+++ b/lisp/textmodes/sgml-mode.el	Sun Apr 14 12:49:39 2002 +0000
@@ -976,7 +976,8 @@
 Assume that parsing starts from within a textual context.
 Leave point at the beginning of the tag."
   (let (tag-type tag-start tag-end name)
-    (search-backward ">")
+    (or (search-backward ">" nil 'move)
+        (error "No tag found"))
     (setq tag-end (1+ (point)))
     (cond
      ((sgml-looking-back-at "--")   ; comment