From: Kim F. Storm Date: Wed, 12 Jul 2006 13:14:00 +0000 (+0000) Subject: (CHECK_FRAME, CHECK_LIVE_FRAME): Use CHECK_TYPE. X-Git-Tag: emacs-pretest-22.0.90~1515 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=915a3e00ad84c76d314cfff3d1d984cd418cc407;p=emacs.git (CHECK_FRAME, CHECK_LIVE_FRAME): Use CHECK_TYPE. --- diff --git a/src/frame.h b/src/frame.h index 940b5409636..50e7c0660b4 100644 --- a/src/frame.h +++ b/src/frame.h @@ -760,18 +760,11 @@ typedef struct frame *FRAME_PTR; (f)->visible = (f)->async_visible, \ (f)->iconified = (f)->async_iconified) -#define CHECK_FRAME(x) \ - do { \ - if (! FRAMEP (x)) \ - x = wrong_type_argument (Qframep, (x)); \ - } while (0) - -#define CHECK_LIVE_FRAME(x) \ - do { \ - if (! FRAMEP (x) \ - || ! FRAME_LIVE_P (XFRAME (x))) \ - x = wrong_type_argument (Qframe_live_p, (x)); \ - } while (0) +#define CHECK_FRAME(x) \ + CHECK_TYPE (FRAMEP (x), Qframep, x) + +#define CHECK_LIVE_FRAME(x) \ + CHECK_TYPE (FRAMEP (x) && FRAME_LIVE_P (XFRAME (x)), Qframe_live_p, x) /* FOR_EACH_FRAME (LIST_VAR, FRAME_VAR) followed by a statement is a `for' loop which iterates over the elements of Vframe_list. The