help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: SMIE & transpose-sexps


From: Stefan Monnier
Subject: Re: SMIE & transpose-sexps
Date: Thu, 27 Feb 2014 21:30:27 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

> And that this would be both jolly useful in itself, and proof that I'd
> set up the parsing rules correctly.  But it doesn't work, and I have
> no idea why.

It usually works for the "=" case but not for the AND case.

The reason is that transpose-sexps doesn't actually know about SMIE
tokens, so when it sees AND it has no idea it's an infix operator,
instead it uses the syntax-tables and thinks AND is an identifier.
For infix operators which are made of symbols (i.e. chars of
"punctuation" syntax), it happens to do the right thing, which is
neat indeed.


        Stefan




reply via email to

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