all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* mode-specific sexps
@ 2004-10-09 23:34 Joe Corneli
  0 siblings, 0 replies; 2+ messages in thread
From: Joe Corneli @ 2004-10-09 23:34 UTC (permalink / raw)


Note that the syntax of sexps is not quite right for use in all
modes.  For example, <1000 is considered to be one sexp and you can
legitimately set it in lisp modes -- (setq <1000 10) -- however, in
LaTeX mode I think this should be regarded as two sexps, a `<'
together with a `1000'.  Advice on to change the definition of a
sexp for LaTeX mode would be appreciated.  My initial investigations
led to `scan-sexps' but this is in C code and I'm hesitant about
messing with that if I don't need to.

I'll probably have some followup questions on this topic related to
my austex.el minor mode

 http://www.ma.utexas.edu/~jcorneli/a/elisp/austex.el

(also in gnu.emacs.sources recently), but this seems like a good
place to start.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: mode-specific sexps
       [not found] <mailman.2316.1097365320.2017.help-gnu-emacs@gnu.org>
@ 2004-10-11 18:27 ` Stefan Monnier
  0 siblings, 0 replies; 2+ messages in thread
From: Stefan Monnier @ 2004-10-11 18:27 UTC (permalink / raw)


> Note that the syntax of sexps is not quite right for use in all
> modes.  For example, <1000 is considered to be one sexp and you can
> legitimately set it in lisp modes -- (setq <1000 10) -- however, in
> LaTeX mode I think this should be regarded as two sexps, a `<'
> together with a `1000'.  Advice on to change the definition of a
> sexp for LaTeX mode would be appreciated.  My initial investigations
> led to `scan-sexps' but this is in C code and I'm hesitant about
> messing with that if I don't need to.

Read the section about syntax-tables in the elisp manual.
It won't answer your question, but it should hopefully help you rewrite your
question so we can give you a more useful answer.

If the question was

   how do I get (forward-sexp 2) to step over "<1111", then the answer is
   somewhere between "you can't" and "maybe try forward-sexp-function".


-- Stefan

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-10-11 18:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-10-09 23:34 mode-specific sexps Joe Corneli
     [not found] <mailman.2316.1097365320.2017.help-gnu-emacs@gnu.org>
2004-10-11 18:27 ` Stefan Monnier

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.