Raymond Toy writes:
> Is this behavior actually useful?
Yes. Slime basically does (goto-char
(next-single-char-property-change
<args>)), which obviously breaks with xemacs when n-s-c-p-c returns
nil.
Sure. But my question is, "is it useful to end up at the end of the
buffer if there are no more property changes?" This is basically a
search function, and there are four behaviors I can think of here:
error, go to end of text, wrap around, do nothing. The first is worse
than useless, but it's not obvious a priori that "return end of text"
has an advantage over the other two except to avoid a trivial change:
;; the "or" is a no-op in Emacs
(goto-char (or (next-single-char-property-change ...)
(the-place-slime-really-wants-to-be)))
At least emacs says n-s-c-p-c is supposed to return the end of the
object when there is no more n-s-c-p-c.
It's arguable this is not very useful, since that behavior is already
available in XEmacs:
(next-single-char-property-change POS PROP nil (point-max))
So the question is really, is the code of the form
(while (not (eobp))
(goto-char (next-single-char-property-change (point) PROP))
;; It's useful to do something at eob! Do it there too!
(do-something))
_______________________________________________
XEmacs-Beta mailing list
XEmacs-Beta(a)xemacs.org
http://lists.xemacs.org/mailman/listinfo/xemacs-beta