GNU bug report logs - #12686
PATCH: ambiguous help doc strings

Previous Next

Package: emacs;

Reported by: "Aaron S. Hawley" <aaron.s.hawley <at> gmail.com>

Date: Fri, 19 Oct 2012 21:01:01 UTC

Severity: minor

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


Message #14 received at 12686 <at> debbugs.gnu.org (full text, mbox):

From: "Aaron S. Hawley" <aaron.s.hawley <at> gmail.com>
To: Juri Linkov <juri <at> jurta.org>
Cc: 12686 <at> debbugs.gnu.org
Subject: Re: bug#12686: PATCH: ambiguous help doc strings
Date: Tue, 23 Oct 2012 11:24:01 -0400
> To avoid crashes after loading all the libraries I suggest to try
> static analysis without loading the libraries.  This is possible
> to do with a function like `emacs-lisp-grep' from
> http://lists.gnu.org/archive/html/emacs-devel/2005-05/msg01259.html

Nice.

> When the first element of an expression read from the source file
> is `defun', its docstring is in the fourth element.  A variable name
> is the second element of the expression whose first element is `defvar'
> or `defcustom', etc.  Conditional defvars are more tricky to process
> but fortunately they are rare.

For this problem, this would require two passes.  The first pass to
find the ambiguous symbol definitions (a defun and defvar or
defcustom) then a second to find the references to these symbols in
documentation in an ambiguous way.  I'd probably use something like an
obarray to keep track of symbols in the first pass, but it would be a
second-rate reimplementation to what Emacs already does.  And
`emacs-lisp-grep' wouldn't search the C sources.  So for laziness and
completeness, I went with mapatoms.

-- 
In general, we reserve the right to have a poor
memory--the computer, however, is supposed to
remember!  Poor computer.  -- Guy Lewis Steele Jr.




This bug report was last modified 12 years and 131 days ago.

Previous Next


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