all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Lars Ingebrigtsen <larsi@gnus.org>
To: Andreas Schwab <schwab@linux-m68k.org>
Cc: 18966@debbugs.gnu.org, Tom Tromey <tom@tromey.com>,
	Stefan Monnier <monnier@iro.umontreal.ca>
Subject: bug#18966: 25.0.50; unhelpful error message from byte compiler
Date: Fri, 21 Aug 2020 13:20:01 +0200	[thread overview]
Message-ID: <87h7sw8cv2.fsf@gnus.org> (raw)
In-Reply-To: <87lfi9kwms.fsf@igel.home> (Andreas Schwab's message of "Thu, 20 Aug 2020 20:19:55 +0200")

Andreas Schwab <schwab@linux-m68k.org> writes:

> On Aug 20 2020, Lars Ingebrigtsen wrote:
>
>> Like in bug#35186, I'm not able to actually chase down where this error
>> message comes from.
>
> It's just a generic macro expansion error:
>
> ELISP> (macroexpand '(push zzz))
> *** Eval error ***  Wrong number of arguments: (2 . 2), 1
> ELISP> (push zzz)
> *** Eval error ***  Wrong number of arguments: (2 . 2), 1

Hm...  I grepped through *.c for the error, and the place where it seems
to actually trigger in the test case:

./src/emacs -Q --batch -f batch-byte-compile /tmp/t.el 
-> /tmp/t.el:3:1: Error: Wrong number of arguments: (2 . 2), 1

Is here:

Lisp_Object
exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
		Lisp_Object args_template, ptrdiff_t nargs, Lisp_Object *args)
{
[...]
      if (! (mandatory <= nargs && nargs <= maxargs))
	Fsignal (Qwrong_number_of_arguments,
		 list2 (Fcons (make_fixnum (mandatory), make_fixnum (nonrest)),
			make_fixnum (nargs)));

Which seems odd -- you'd expect it to bug out much earlier, in
macroexpand, as Andreas says.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





      reply	other threads:[~2020-08-21 11:20 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-05 23:54 bug#18966: 25.0.50; unhelpful error message from byte compiler Tom Tromey
2020-08-20 17:54 ` Lars Ingebrigtsen
2020-08-20 18:19   ` Andreas Schwab
2020-08-21 11:20     ` Lars Ingebrigtsen [this message]

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=87h7sw8cv2.fsf@gnus.org \
    --to=larsi@gnus.org \
    --cc=18966@debbugs.gnu.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=schwab@linux-m68k.org \
    --cc=tom@tromey.com \
    /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.