emacs-devel
[Top][All Lists]
Advanced

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

Re: Macro CHECK_NUMBER?


From: Pavel Janík
Subject: Re: Macro CHECK_NUMBER?
Date: Thu, 25 Oct 2001 23:51:15 +0200
User-agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.1.50 (i386-suse-linux-gnu)

   From: Ken Raeburn <address@hidden>
   Date: Thu, 25 Oct 2001 08:58:43 -0400

   > The second argument to CHECK_NUMBER is an integer, which I've always
   > thought was the function argument number.

But this macro is not always used for checking the type of arguments - look
at xfns.c, line 1467:

void
x_set_mouse_color (f, arg, oldval)
     struct frame *f;
     Lisp_Object arg, oldval;
{
...
  if (!NILP (Vx_pointer_shape))
    {
      CHECK_NUMBER (Vx_pointer_shape, 0);
      cursor = XCreateFontCursor (dpy, XINT (Vx_pointer_shape));
    }
...

We are checking the variable which is not an argument. What should we do
here? Should we use 0 for this case and 1, ... as an argument number and
report that appropriately?
-- 
Pavel Janík

panic("mother...");
                  -- 2.2.16 drivers/block/cpqarray.c



reply via email to

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