GNU bug report logs - #20385
Support curved quotes in doc strings

Previous Next

Package: emacs;

Reported by: Paul Eggert <eggert <at> cs.ucla.edu>

Date: Mon, 20 Apr 2015 18:40:04 UTC

Severity: wishlist

Tags: patch

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Dmitry Gutov <dgutov <at> yandex.ru>, 20385 <at> debbugs.gnu.org
Subject: bug#20385: [PATCH] Support curved quotes in doc strings
Date: Thu, 21 May 2015 07:58:57 -0700
Dmitry Gutov wrote:
> I'd make it a new function (the name doesn't fit), and pass the docstring
> contents through it, before giving them to substitute-command-keys.

I originally wrote it that way, but it was harder for me to read.  (Also slower, 
though that doesn't matter these days.)  I couldn't find anybody that would want 
to call one function but not the other.  Plus, having them be separate functions 
introduces more opportunity for error, e.g., it wouldn't be correct to call the 
new function after calling substitute-command-keys.  So I figured we might as 
well leave them combined.

How about if we rename substitute-command-keys to describe it better? 
substitute-doc-string, perhaps?

> And if you write it in Lisp, you could incorporate the special handling of
> quasiquotes relatively easily.

Yes, I originally wrote it in Lisp too, but found that it was too tempting to 
implement complicated heuristics that would have been a pain to document.  (I 
even defended some of those heuristics in previous emails -- sorry!)  Doing it 
in C forced me to come up with something really simple and easy to explain.  I'd 
rather keep the simple rules now, even if we go back to Lisp (but why bother?).




This bug report was last modified 9 years and 364 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.