emacs-devel
[Top][All Lists]
Advanced

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

Re: [Emacs-diffs] master b533552 2/5: Documentation fixes re quotes


From: Dmitry Gutov
Subject: Re: [Emacs-diffs] master b533552 2/5: Documentation fixes re quotes
Date: Fri, 4 Sep 2015 01:08:49 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:40.0) Gecko/20100101 Thunderbird/40.0

On 09/04/2015 12:50 AM, Paul Eggert wrote:

If the programmer types ‘foo‘, they can easily miss the non-matching
quotes

First, the two scenarios are the same in the typical text-quoting-style
case, because the output looks like ‘foo‘ either way,

Not if the translation logic checks for pairing. This is not true of the current code (IIUC), but it was true not too long ago, and that's what Stefan's asking for as well.

and whatever
method works for detecting input `foo` will work equally well for
detecting input ‘foo‘.

What method are you thinking of? Lint-like highlighting in red is only feasible if the syntax is strict.

Second and more important, it’s more efficient to detect and fix this
issue immediately while typing, as the highlighting around the foo won’t
be as expected and a programmer can see that easily right away and just
backspace and fix the bad quote while it’s fresh.

Checking highlighting is good, but it only works when we're quoting simple symbols. Not Lisp expressions, key sequences or anything else like that.

Also, please recall that highlighting is performed in Lisp. Since you've opted to do translation in C, font-lock cannot accurately handle the quoting syntax, with escapes and etc.

It’d be considerably
more awkward and error-prone to detect the problem only when it’s
rendered into a *Help* buffer.

Checking that the output looks right is a natural urge either way.

My main point is, in general, non-translating "markup" invites typos.

Emacs is powerful enough to paper over many problems, but maybe one should take a hint earlier and spend effort where it really matters.



reply via email to

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