summaryrefslogtreecommitdiff
path: root/src/dispextern.h
diff options
context:
space:
mode:
authorDmitry Antipov <dmantipov@yandex.ru>2012-06-28 11:50:50 +0400
committerDmitry Antipov <dmantipov@yandex.ru>2012-06-28 11:50:50 +0400
commite509cfa6065d20e0d8d2b3ce9ac544355521bc89 (patch)
tree49bb60b82e50f987bdaa095963d07b1c66a5a109 /src/dispextern.h
parenta54e2c050b9cf161cbccc3dd4628f8ef6b64f519 (diff)
downloademacs-e509cfa6065d20e0d8d2b3ce9ac544355521bc89.tar.gz
* configure.in: Add glyphs category to --enable-checking option.
(GLYPH_DEBUG): Define if glyphs debugging is enabled. * src/dispextern.h (GLYPH_DEBUG): Now defined in config.h if enabled with --enable-checking=[all,glyphs] configure option. Fix GLYPH_DEBUG usage assuming that it may be undefined, adjust comments accordingly. * src/dispnew.c: Fix GLYPH_DEBUG usage assuming that it may be undefined, adjust comments accordingly. * src/image.c: Likewise. * src/scroll.c: Likewise. * src/w32fns.c: Likewise. * src/w32term.c: Likewise. * src/xdisp.c: Likewise. * src/xfaces.c: Likewise. * src/xfns.c: Likewise. * src/xterm.c: Likewise.
Diffstat (limited to 'src/dispextern.h')
-rw-r--r--src/dispextern.h31
1 files changed, 13 insertions, 18 deletions
diff --git a/src/dispextern.h b/src/dispextern.h
index 78f6db63cb7..c7adc4dadec 100644
--- a/src/dispextern.h
+++ b/src/dispextern.h
@@ -121,26 +121,21 @@ enum window_part
Debugging
***********************************************************************/
-/* If GLYPH_DEBUG is non-zero, additional checks are activated. Turn
- it off by defining the macro GLYPH_DEBUG to zero. */
+/* If GLYPH_DEBUG is defined, additional checks are activated. */
-#ifndef GLYPH_DEBUG
-#define GLYPH_DEBUG 0
-#endif
-
-/* Macros to include code only if GLYPH_DEBUG != 0. */
+/* Macros to include code only if GLYPH_DEBUG is defined. */
-#if GLYPH_DEBUG
+#ifdef GLYPH_DEBUG
#define IF_DEBUG(X) X
#else
#define IF_DEBUG(X) (void) 0
#endif
/* Macro for displaying traces of redisplay. If Emacs was compiled
- with GLYPH_DEBUG != 0, the variable trace_redisplay_p can be set to
+ with GLYPH_DEBUG defined, the variable trace_redisplay_p can be set to
a non-zero value in debugging sessions to activate traces. */
-#if GLYPH_DEBUG
+#ifdef GLYPH_DEBUG
extern int trace_redisplay_p EXTERNALLY_VISIBLE;
#include <stdio.h>
@@ -151,11 +146,11 @@ extern int trace_redisplay_p EXTERNALLY_VISIBLE;
else \
(void) 0
-#else /* GLYPH_DEBUG == 0 */
+#else /* not GLYPH_DEBUG */
#define TRACE(X) (void) 0
-#endif /* GLYPH_DEBUG == 0 */
+#endif /* GLYPH_DEBUG */
@@ -653,7 +648,7 @@ struct glyph_matrix
line. */
unsigned header_line_p : 1;
-#if GLYPH_DEBUG
+#ifdef GLYPH_DEBUG
/* A string identifying the method used to display the matrix. */
char method[512];
#endif
@@ -671,7 +666,7 @@ struct glyph_matrix
/* Check that glyph pointers stored in glyph rows of MATRIX are okay.
This aborts if any pointer is found twice. */
-#if GLYPH_DEBUG
+#ifdef GLYPH_DEBUG
void check_matrix_pointer_lossage (struct glyph_matrix *);
#define CHECK_MATRIX(MATRIX) check_matrix_pointer_lossage ((MATRIX))
#else
@@ -950,10 +945,10 @@ struct glyph_row
/* Get a pointer to row number ROW in matrix MATRIX. If GLYPH_DEBUG
- is defined to a non-zero value, the function matrix_row checks that
- we don't try to access rows that are out of bounds. */
+ is defined, the function matrix_row checks that we don't try to
+ access rows that are out of bounds. */
-#if GLYPH_DEBUG
+#ifdef GLYPH_DEBUG
struct glyph_row *matrix_row (struct glyph_matrix *, int);
#define MATRIX_ROW(MATRIX, ROW) matrix_row ((MATRIX), (ROW))
#else
@@ -3067,7 +3062,7 @@ extern void produce_stretch_glyph (struct it *);
#ifdef HAVE_WINDOW_SYSTEM
-#if GLYPH_DEBUG
+#ifdef GLYPH_DEBUG
extern void dump_glyph_string (struct glyph_string *) EXTERNALLY_VISIBLE;
#endif