emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: scheme.el bug & fix


From: Luc Teirlinck
Subject: Re: scheme.el bug & fix
Date: Sun, 16 Feb 2003 19:05:36 -0600 (CST)

Stefan Monnier wrote:

   It turns out the problem is that

     (with-syntax-table st (modify-syntex-entry foo bar))

   does not modify `st' because `with-syntax-table' does not use `st'
   but a copy of it.  Actually it's even documented in the docstring.
   This sounds silly.  Does anybody have an idea why it is defined that way ?
   If not, any objection the patch below which should also improve
   (very marginally) the performance of Emacs ?

Are you sure that you are not going to break plenty of existing code
this way?  People could very legitimately have relied on the present
behavior, which is, as you state yourself, very explicitly mentioned
in the doc string.  The reason for the "silly" behavior seems obvious:
to avoid accidental modification of st.

Is there any reason why scheme.el can not possibly define its syntax
table in a more standard and more natural way?  I do not believe that 
with-syntax-table was meant to be used the way scheme .el uses it.
(I believe it is meant to very temporarily change the syntax table of
the current buffer, not to be used to actually define syntax tables.)


Sincerely,

Luc.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]