[Top][All Lists]

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

Re: skeleton.el _ versus @

From: Stefan Monnier
Subject: Re: skeleton.el _ versus @
Date: Tue, 01 Apr 2003 20:33:29 -0500

> It seems clear to me that the "backing-up" of _ with @ was an
> ill-conceived back-of-the-hand programming insertion to solve someone's
> region-mode problem.  It clearly was ill-thought out because it
> completely fails in normal insertion mode when you mix @ and _, as
> mmm-mode does.

Could ou give an real example where it "completely fails" ?
I understand that the behavior is different, but your previous
example is not very compelling since the difference is only
an "off by one" position.

> I can imagine that a solution is to have skeleton-insert examine the use
> made of @ and _ ex-post-facto.

No.  The two different situations can only be told apart by
asking the author.  In (nil "fun " str "(" @ ")" \n "{" \n _ "}"),
point should always end inside the parens.

> When you look at the design of skeleton-mode, _ is clearly the preferred
> way to set skeleton-point.  I really just cannot see how to justify
> completely abandoning the meaning of _ in any situation at all.  I can

_ indicates where to insert the region(s).

> perversion of the clear separation between _ and @.  My question is when
> was the _ @ distinction ruined by allowing @ to override the meaning of _.

In Emacs-21.1.

> Was it introduced by the original skeleton author, or was it
> inserted on-the-sly by someone else?

It was introduced by yours truly.  The reasoning behind it was
that editing generally takes place left-to-right, so point
should most naturally end up at the first interesting position.
Also it allowed to distinguish between where point should go
and where the region should go.


reply via email to

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