# HG changeset patch # User Stefan Monnier # Date 1017268064 0 # Node ID ee2adfa7e248bc66e29ae3557f42e1de3f47495a # Parent dcccdfe562685c242a470c58e52fc4f8d7937952 (xml-lite-in-string-p): Simplify. diff -r dcccdfe56268 -r ee2adfa7e248 lisp/textmodes/xml-lite.el --- a/lisp/textmodes/xml-lite.el Wed Mar 27 22:26:22 2002 +0000 +++ b/lisp/textmodes/xml-lite.el Wed Mar 27 22:27:44 2002 +0000 @@ -95,15 +95,17 @@ (bolp))) (defun xml-lite-in-string-p (&optional limit) - "Determine whether point is inside a string." + "Determine whether point is inside a string. + +Parse begins from LIMIT, which defaults to the preceding occurence of a tag +at the beginning of a line." (let (syntax-info) (or limit (setq limit (or (save-excursion (re-search-backward "^[ \t]*<" nil t)) (point-min)))) (setq syntax-info (parse-partial-sexp limit (point))) - (if (nth 3 syntax-info) - (list (nth 3 syntax-info) (nth 8 syntax-info))))) + (if (nth 3 syntax-info) (nth 8 syntax-info)))) ;; Parsing