all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Gemini Lasswell <gazally@runbox.com>
To: 24743@debbugs.gnu.org
Subject: bug#24743: 26.0.50; Testcover does not correctly instrument a macro that uses defun
Date: Wed, 19 Oct 2016 16:51:08 -0700	[thread overview]
Message-ID: <m28ttj99ub.fsf@rainbow.local> (raw)

Testcover doesn't work on lisp/isearch.el in the Emacs source tree. It
fails on the first use of isearch-define-mode-toggle. I've created a
much simpler example which produces the same error message:

(defmacro my-defun (name &rest body)
  (declare (debug (symbolp def-body)))
  `(defun ,name () ,@body))

(my-defun foo (+ 1 2))

To reproduce the bug:
1. Save the above code as bug.el
2. emacs -Q
3. C-x C-f bug.el RET
4. M-: (require 'testcover) RET
5. M-x testcover-start RET bug.el RET

Result: "Wrong type argument: consp, nil" and foo does not get defined.
(symbol-function #'my-defun) reveals that there is a call to
edebug-after in the definition that did not get replaced by testcover-after.

In GNU Emacs 26.0.50.2 (x86_64-apple-darwin15.6.0, NS appkit-1404.47 Version 10.11.6 (Build 15G1004))
 of 2016-10-19 built on rainbow.local
Repository revision: 911ade134058c633ab9bec75f664d44aa1faaac3
Windowing system distributor 'Apple', version 10.3.1404
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
testcover
Edebug: my-defun
Eager macro-expansion failure: (wrong-type-argument consp nil) [2 times]
cons: Wrong type argument: consp, nil
Configured using:
 'configure --with-ns --disable-ns-self-contained'

Configured features:
JPEG RSVG IMAGEMAGICK NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS
NS

Important settings:
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Emacs-Lisp

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message subr-x puny seq byte-opt gv
bytecomp byte-compile cl-extra help-mode cconv dired dired-loaddefs
format-spec rfc822 mml mml-sec password-cache epa derived epg epg-config
gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode mail-parse
rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045
ietf-drums mm-util mail-prsvr mail-utils ielm pp comint ansi-color ring
testcover edebug easymenu cl-loaddefs pcase cl-lib time-date mule-util
tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type
mwheel term/ns-win ns-win ucs-normalize term/common-win tool-bar dnd
fontset image regexp-opt fringe tabulated-list newcomment elisp-mode
lisp-mode prog-mode register page menu-bar rfn-eshadow timer select
scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932
hebrew greek romanian slovak czech european ethiopic indian cyrillic
chinese charscript case-table epa-hook jka-cmpr-hook help simple abbrev
obarray minibuffer cl-preloaded nadvice loaddefs button faces cus-face
macroexp files text-properties overlay sha1 md5 base64 format env
code-pages mule custom widget hashtable-print-readable backquote kqueue
cocoa ns multi-tty make-network-process emacs)

Memory information:
((conses 16 212236 12367)
 (symbols 48 20872 0)
 (miscs 40 58 213)
 (strings 32 20332 5553)
 (string-bytes 1 648497)
 (vectors 16 35663)
 (vector-slots 8 676706 4164)
 (floats 8 180 171)
 (intervals 56 257 0)
 (buffers 976 13))





             reply	other threads:[~2016-10-19 23:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-19 23:51 Gemini Lasswell [this message]
2016-10-22  1:04 ` bug#24743: 26.0.50; Testcover does not correctly instrument a macro that uses defun Gemini Lasswell
2017-10-08 23:44 ` Gemini Lasswell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m28ttj99ub.fsf@rainbow.local \
    --to=gazally@runbox.com \
    --cc=24743@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.