all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Stefan Kangas <stefan@marxist.se>
Cc: Lars Ingebrigtsen <larsi@gnus.org>,  emacs-devel@gnu.org
Subject: Re: Zero byte-compiler warnings in the test suite
Date: Wed, 22 Dec 2021 12:40:54 -0500	[thread overview]
Message-ID: <jwvilvg4jyv.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <CADwFkmnEkSPmM6CNi7PuGC+YQPOvByF9fRSrjySOgNiY25Q2gA@mail.gmail.com> (Stefan Kangas's message of "Tue, 21 Dec 2021 21:07:52 -0800")

>> The test expects the error to be signal'd at run time whereas the
>> compiler macro prefers to signal the error right away.
>> As a bias observer, I'd suggest to fix the test rather than the compiler
>> macro ;-)
>
> How do we usually test compiler macros?  I guess we should create a
> separate file and try to byte-compile it?

I'd do something like

    (should-error
     (macroexpand-all '(pcase ...)))


-- Stefan




  reply	other threads:[~2021-12-22 17:40 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-21 12:36 Zero byte-compiler warnings in the test suite Stefan Kangas
2021-12-21 13:09 ` Lars Ingebrigtsen
2021-12-21 13:39   ` Stefan Kangas
2021-12-21 13:49     ` Lars Ingebrigtsen
2021-12-21 15:11       ` Stefan Kangas
2021-12-21 15:41     ` Stefan Monnier
2021-12-22  5:07       ` Stefan Kangas
2021-12-22 17:40         ` Stefan Monnier [this message]
2021-12-22 22:11           ` Stefan Kangas
2021-12-23  0:07             ` Weird non-caught error in ERT (was: Zero byte-compiler warnings in the test suite) Stefan Monnier
2021-12-23 10:04               ` Philipp Stephani
2021-12-21 14:54 ` Zero byte-compiler warnings in the test suite Eli Zaretskii

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=jwvilvg4jyv.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=emacs-devel@gnu.org \
    --cc=larsi@gnus.org \
    --cc=stefan@marxist.se \
    /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.