On 3/14/07, Stephen J. Turnbull <turnbull@sk.tsukuba.ac.jp> wrote:
Reply-To set to xemacs-beta; no need to bother auctex-devel further
with XEmacs internal details.


OK.  I left Ralf in the CC.


Ralf Angeli writes:

> revision 1.29
> date: 2003/03/02 09:38:40;  author: ben;  state: Exp;  lines: +440 -202
>
> [...] subr.el, view-less.el, wid-edit.el: Lots of syncing with FSF 21.2.

> With that change the whole macro was copied into subr.el

Thank you very much!  And I see in an earlier post you've already
identified the place where current Emacs diverged, which was done by
Stefan Monnier.  I'm convinced; we don't need to understand the
underlying implementation (I thought we did need to understand
copy-syntax-table, at least, but in the first place that call was
evidently just a thinko that we sync'ed to), only to test that

(let ((copy (copy-syntax-table (syntax-table))))
  (or
    (with-syntax-table (obviously-different-from-current-syntax-table)
      (test-syntax-table-equal copy (syntax-table)))
    (not (test-syntax-table-equal copy (syntax-table)))))

evaluates to nil, as we expect.  ( N.B. XEmacs's implementation of
syntax tables is sparse, so #'equal need not give the right results.
In particular, (make-syntax-table) and (standard-syntax-table) return
objects that are equivalent as syntax tables but not #'equal.)

(Thinking out loud ....)  Regression tests for the bug and that
with-syntax-table works as expected should be added.  Also review uses
in core (probably none) and the packages (probably few or none outside
of Gnus and AUCTeX).  The use case review can be done "off-line".  Is
this relevant to 21.4?


There are 3 uses in 21.5 core that I can see, all in  help.el, and none of them modify the syntax table.  I'll check packages later.
 

Robert, do you agree with the above analysis based on what you've seen
so far?  Would you be willing to help with some part of the code
review and/or test-writing?


Seems accurate.

I'll do the checking, and come up with some test cases.  Not until later today or tomorrow though, I have Real Work to do first ;-)

Regards

Robert