[Top][All Lists]

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

bug#25077: 25.1; Incorrect Edebug spec for c-lang-defvar

From: Alan Mackenzie
Subject: bug#25077: 25.1; Incorrect Edebug spec for c-lang-defvar
Date: Sat, 18 Feb 2017 16:10:52 +0000
User-agent: Mutt/1.7.2 (2016-11-26)

Hello, Gemini and Eli.

On Sat, Feb 04, 2017 at 13:27:45 +0200, Eli Zaretskii wrote:
> > From: Gemini Lasswell <address@hidden>
> > Date: Wed, 30 Nov 2016 11:20:28 -0800

> > The Edebug spec for c-lang-defvar doesn't allow for the use of
> > 'dont-doc, which prevents the use of Edebug and Testcover on
> > cc-langs.el.

> > To reproduce, using emacs -Q starting at the root of the Emacs
> > sources:

> > M-: (require 'cc-langs) RET
> > C-x C-f lisp/progmodes/cc-langs.el RET
> > C-s dont-doc RET
> > C-u C-M-x

> > Result: edebug-syntax-error: Invalid read syntax: stringp, "failed"

> > I tried this change to the Edebug spec for c-lang-defvar, and it makes
> > Edebug work on all the c-lang-defvar uses in this file:

> > (def-edebug-spec c-lang-defvar
> >   (&define name def-form &optional &or ("quote" "dont-doc") stringp))

Thanks, both for reporting this bug and for fixing it.  :-)

> > Alternatively, the 'dont-doc could be removed from the 7 places it is
> > used. The majority of c-lang-defvar calls simply omit the docstring,
> > and the code in c-lang-defvar is not doing any checking for dont-doc,
> > it simply ignores that parameter if it is not a string.

After some consideration, I amended the edebug-spec like you suggested,
but also removed the two occurrences of 'dont-doc which had no effect.

I've committed the change to master, and I'm closing this bug as fixed.

> Alan, could you please look into this?

> Thanks.

Alan Mackenzie (Nuremberg, Germany).

reply via email to

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