[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: hack-local-variables bug?
From: |
David PONCE |
Subject: |
Re: hack-local-variables bug? |
Date: |
Wed, 16 Mar 2005 09:11:30 +0100 (CET) |
Hi,
> You've analyzed the bug right, but the fix is not right. Your
> change binds case-fold-search over a long part of the code. The
> right change is to bind it only around the call to re-search-forward
> that searches for End.
Is the following patch better? I can commit it if it helps.
David
2005-03-16 David Ponce <address@hidden>
* files.el (hack-local-variables): Do a case-insensitive search
for End.
Index: lisp/files.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/files.el,v
retrieving revision 1.745
diff -c -r1.745 files.el
*** lisp/files.el 9 Feb 2005 15:50:42 -0000 1.745
--- lisp/files.el 16 Mar 2005 08:05:59 -0000
***************
*** 2247,2256 ****
endpos
(thisbuf (current-buffer)))
(save-excursion
! (if (not (re-search-forward
! (concat prefix "[ \t]*End:[ \t]*" suffix)
! nil t))
! (error "Local variables list is not properly terminated"))
(beginning-of-line)
(setq endpos (point)))
--- 2247,2257 ----
endpos
(thisbuf (current-buffer)))
(save-excursion
! (unless (let ((case-fold-search t))
! (re-search-forward
! (concat prefix "[ \t]*End:[ \t]*" suffix)
! nil t))
! (error "Local variables list is not properly terminated"))
(beginning-of-line)
(setq endpos (point)))