r1372@localhost: muntyan | 2005-12-13 00:42:53 -0600

Use MOO_DEBUG for any checks
master
Yevgen Muntyan 2005-12-13 12:44:02 +00:00
parent 79e366138a
commit 38816217a4
8 changed files with 23 additions and 18 deletions

View File

@ -2,18 +2,20 @@
# MOO_AC_DEBUG()
#
AC_DEFUN([MOO_AC_DEBUG],[
MOO_DEBUG="no"
MOO_DEBUG_CFLAGS=
MOO_DEBUG_CXXFLAGS=
AC_ARG_ENABLE(debug,
AC_HELP_STRING([--enable-debug],[enable debug options (default = NO)]),[
if test "x$enable_debug" = "xno"; then
debug="no"
MOO_DEBUG="no"
else
debug="yes"
MOO_DEBUG="yes"
MOO_DEBUG="yes"
fi
],[
debug="no"
MOO_DEBUG="no"
])
AC_ARG_ENABLE(all-gcc-warnings,
@ -66,10 +68,10 @@ MOO_DEBUG_CXXFLAGS="$MOO_DEBUG_GCC_CXXFLAGS $MOO_DEBUG_CXXFLAGS -W -Wall -Woverl
MOO_DEBUG_CXXFLAGS=$MOO_DEBUG_GCC_CXXFLAGS
fi
if test x$debug = "xyes"; then
if test x$MOO_DEBUG = "xyes"; then
moo_debug_flags="-DG_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED dnl
-DGDK_DISABLE_DEPRECATED -DDEBUG -DENABLE_DEBUG -DENABLE_PROFILE dnl
-DG_ENABLE_DEBUG -DG_ENABLE_PROFILE"
-DG_ENABLE_DEBUG -DG_ENABLE_PROFILE -DMOO_DEBUG=1"
else
moo_debug_flags="-DNDEBUG=1 -DG_DISABLE_CAST_CHECKS -DG_DISABLE_ASSERT"
fi

View File

@ -36,7 +36,7 @@
<useconfiguration>debug</useconfiguration>
</general>
<run>
<mainprogram>medit</mainprogram>
<mainprogram>./medit</mainprogram>
<directoryradio>executable</directoryradio>
<customdirectory>/</customdirectory>
<programargs></programargs>
@ -192,7 +192,7 @@
<abortonerror>true</abortonerror>
<numberofjobs>1</numberofjobs>
<dontact>false</dontact>
<makebin></makebin>
<makebin/>
<prio>0</prio>
</make>
</kdevautoproject>
@ -268,16 +268,16 @@
</kdevdoctreeview>
<kdevfilecreate>
<filetypes>
<type icon="source" ext="g" name="GAP source" create="template" >
<type icon="source" ext="g" create="template" name="GAP source" >
<descr>A new empty GAP source file</descr>
</type>
<type icon="source_cpp" ext="cpp" name="C++ Source" create="template" >
<type icon="source_cpp" ext="cpp" create="template" name="C++ Source" >
<descr>A new empty C++ file.</descr>
</type>
<type icon="source_h" ext="h" name="C/C++ Header" create="template" >
<type icon="source_h" ext="h" create="template" name="C/C++ Header" >
<descr>A new empty header file for C/C++.</descr>
</type>
<type icon="source_c" ext="c" name="C Source" create="template" >
<type icon="source_c" ext="c" create="template" name="C Source" >
<descr>A new empty C file.</descr>
</type>
</filetypes>

View File

@ -1,6 +1,6 @@
mooedit/mootextbtree.c: CHECK_INTEGRITY
mooutils/moofileview/moofoldermodel-private.h: DEFINE_CHECK_FILE_LIST_INTEGRITY
mooterm/mootermline.h: #if 0...
mooterm/mootermline-private.h: #if 0...
mooterm: remove dependency on yacc
mooedit/moohighlighter.c:iter_get_syntax_tag(): #if 0 ...
mooedit/moolang.h; mooedit/moolang-rules.c: Rule::debug_string

View File

@ -17,8 +17,11 @@
#include "mooutils/moomarshals.h"
#ifdef MOO_DEBUG
#define WANT_CHECKS 1
#else
#define WANT_CHECKS 0
#endif
static void moo_fold_finalize (GObject *object);
static void moo_fold_free_recursively (MooFold *fold);

View File

@ -157,7 +157,7 @@ iter_get_syntax_tag (const GtkTextIter *iter)
{
if (MOO_IS_SYNTAX_TAG (l->data))
{
#if 0
#ifndef MOO_DEBUG
tag = l->data;
break;
#else

View File

@ -33,7 +33,7 @@ static void bt_data_free (BTData *data,
#define NODE_IS_ROOT(node__) (!(node__)->parent)
#if 0
#if defined(MOO_DEBUG) && 0
#define WANT_CHECK_INTEGRITY
static void CHECK_INTEGRITY (BTree *tree, gboolean check_capacity);
#else

View File

@ -117,7 +117,7 @@ gboolean _moo_term_line_wrapped_chk__ (MooTermLine *line);
#define _moo_term_line_set_wrapped(line__) (line__)->wrapped = TRUE
#if 1
#if MOO_DEBUG
#define _moo_term_line_get_cell(line__,index__) (_moo_term_line_get_cell_chk__(line__, index__))
#define _moo_term_line_get_char(line__,index__) (_moo_term_line_get_char_chk__(line__, index__))
#define _moo_term_line_get_tags(line__,index__) (_moo_term_line_get_tags_chk__(line__, index__))

View File

@ -91,7 +91,7 @@ static void _hash_table_remove (FileList *flist,
MooFile *file);
#ifdef DEBUG
#ifdef MOO_DEBUG
#if 0
#define DEFINE_CHECK_FILE_LIST_INTEGRITY
static void CHECK_FILE_LIST_INTEGRITY (FileList *flist)
@ -115,7 +115,7 @@ static void CHECK_FILE_LIST_INTEGRITY (FileList *flist)
}
}
#endif
#endif /* DEBUG */
#endif /* MOO_DEBUG */
#ifndef DEFINE_CHECK_FILE_LIST_INTEGRITY
#define CHECK_FILE_LIST_INTEGRITY(flist)