Commit 35dccc62 authored by Stefan Monnier's avatar Stefan Monnier
Browse files

(tex-validate-region): Obey syntax-table text properties.

parent d8f96db8
......@@ -1190,14 +1190,14 @@ area if a mismatch is found."
(forward-sexp 1))
;; Now check that like matches like.
(goto-char start)
(while (progn (skip-syntax-forward "^(")
(not (eobp)))
(let ((match (matching-paren (following-char))))
(while (re-search-forward "\\s(" nil t)
(let ((pos (match-beginning 0)))
(goto-char pos)
(forward-sexp 1)
(or (= (preceding-char) match)
(error "Mismatched parentheses"))))
(forward-char 1)))
(or (eq (preceding-char) (cdr (syntax-after pos)))
(eq (char-after pos) (cdr (syntax-after (1- (point)))))
(error "Mismatched parentheses"))))))
(skip-syntax-forward " .>")
(setq failure-point (point)))))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment