changeset 61958:935929fcdb78

(latexenc-find-file-coding-system): Fix regular expressions. Suggested by David Kastrup <dak@gnu.org> and Stefan Monnier <monnier@iro.umontreal.ca>.
author Lute Kamstra <lute@gnu.org>
date Sun, 01 May 2005 11:01:49 +0000
parents 8bd1a070b688
children 055bdb7f1335
files lisp/international/latexenc.el
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/international/latexenc.el	Sun May 01 07:07:19 2005 +0000
+++ b/lisp/international/latexenc.el	Sun May 01 11:01:49 2005 +0000
@@ -121,8 +121,8 @@
         ;; try to find the coding system in this file
         (goto-char (point-min))
         (if (or
-             (re-search-forward "^[^%$]*\\inputencoding{\\(.*\\)}" nil t)
-             (re-search-forward "^[^%$]*\\usepackage\\[\\(.*\\)\\]{inputenc}" nil t))
+             (re-search-forward "^[^%\n]*\\\\inputencoding{\\(.*\\)}" nil t)
+             (re-search-forward "^[^%\n]*\\\\usepackage\\[\\(.*\\)\\]{inputenc}" nil t))
             (let* ((match (match-string 1))
                    (sym (intern match)))
               (when (latexenc-inputenc-to-coding-system match)