Mercurial > urweb
comparison src/elisp/urweb-mode.el @ 393:bc5a56ed0cd6
Fix XML detection in presence of comparison operators
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Tue, 21 Oct 2008 11:13:03 -0400 |
parents | ef43ed6cd1de |
children | 040edfade639 |
comparison
equal
deleted
inserted
replaced
392:a813476230e3 | 393:bc5a56ed0cd6 |
---|---|
177 (incf depth)) | 177 (incf depth)) |
178 ((save-excursion (backward-char 1) (or (looking-at "=>") | 178 ((save-excursion (backward-char 1) (or (looking-at "=>") |
179 (looking-at "->") | 179 (looking-at "->") |
180 (looking-at "<>"))) | 180 (looking-at "<>"))) |
181 nil) | 181 nil) |
182 ((or (looking-at "< ") (looking-at "<=")) | |
183 nil) | |
182 ((looking-at "<") | 184 ((looking-at "<") |
183 (setq finished t)) | 185 (setq finished t)) |
186 ((save-excursion (backward-char 1) (looking-at " >")) | |
187 nil) | |
184 ((looking-at ">") | 188 ((looking-at ">") |
185 (cond | 189 (cond |
186 ((> depth 0) | 190 ((> depth 0) |
187 (if (not (re-search-backward "<" nil t)) | 191 (if (not (re-search-backward "<" nil t)) |
188 (setq finished t))) | 192 (setq finished t))) |
193 ((save-excursion (backward-char 1) (looking-at " ")) | |
194 (setq finished t)) | |
189 (t | 195 (t |
190 (progn (backward-char 4) | 196 (progn (backward-char 4) |
191 (setq answer (not (or | 197 (setq answer (not (or |
192 (looking-at "/xml") | 198 (looking-at "/xml") |
193 (looking-at "xml/")))) | 199 (looking-at "xml/")))) |