emacs-devel
[Top][All Lists]
Advanced

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

Re: [Emacs-diffs] scratch/fix-33794-extend-electric-layout-mode 41a9132:


From: João Távora
Subject: Re: [Emacs-diffs] scratch/fix-33794-extend-electric-layout-mode 41a9132: Extend electric-layout-mode to handle more complex layouts
Date: Fri, 28 Dec 2018 22:00:35 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Stefan Monnier <address@hidden> writes:

> The new API looks good to me, thanks.

Cool.

> Could we pass the inserted char to the function, so the function doesn't
> need to choose between looking at last-command-event, char-before, or
> yet something else?

Passed it last-command event.  Perhaps I should also mention that the
function runs with point set to char-after of the insertion.

> nil doesn't need to be mentioned here, since it's a special case of
> "list of the preceding symbols".

OK, but notice that because of the subtlety that when using the compound
function, nil has the meaning of "no match".  So if that function wants
to match but don't insert anything, it has to return a list of the
single element nil.  So maybe I should add it back to the docstring (I
just pushed the commit that removes it).

> I think I'm fine with allowing MATCHER to be a function, and I'm fine with
> allowing (MATCHER . WHERE) to be a function, but I don't like the idea
> of allowing both, which seem a bit redundant

Makes sense.  MATCHER is only a character now.

Tell me if it's good to go, and if I should squash the scratch branch
into a single commit or just rebase the whole thing onto master, or
merge or whatever.

João



reply via email to

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