[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
could `minibufferp' have an optional BUFFER arg ?
From: |
John Paul Wallington |
Subject: |
could `minibufferp' have an optional BUFFER arg ? |
Date: |
Wed, 25 Sep 2002 14:00:10 +0100 |
Is it a good idea for `minibufferp' to have an optional BUFFER
argument?
If so, is the following reasonable ?
diff -c /build-emacs/emacs/src/minibuf.c.\~1.249.\~
/build-emacs/emacs/src/minibuf.c
*** /build-emacs/emacs/src/minibuf.c.~1.249.~ Tue Aug 13 23:52:05 2002
--- /build-emacs/emacs/src/minibuf.c Wed Sep 25 13:25:39 2002
***************
*** 319,331 ****
}
DEFUN ("minibufferp", Fminibufferp,
! Sminibufferp, 0, 0, 0,
! doc: /* Return t if the current buffer is a minibuffer. */)
! ()
{
Lisp_Object tem;
! tem = Fmemq (Fcurrent_buffer (), Vminibuffer_list);
return ! NILP (tem) ? Qt : Qnil;
}
--- 319,338 ----
}
DEFUN ("minibufferp", Fminibufferp,
! Sminibufferp, 0, 1, 0,
! doc: /* Return t if BUFFER is a minibuffer.
! No argument or nil as argument means use current buffer as BUFFER.*/)
! (buffer)
! Lisp_Object buffer;
{
Lisp_Object tem;
! if (NILP (buffer))
! buffer = Fcurrent_buffer ();
! else
! buffer = Fget_buffer (buffer);
!
! tem = Fmemq (buffer, Vminibuffer_list);
return ! NILP (tem) ? Qt : Qnil;
}
--
John Paul Wallington
- could `minibufferp' have an optional BUFFER arg ?,
John Paul Wallington <=