commit (head): win32 assert implementation (7936)

From: Tomas Frydrych <tomasfrydrych_at_yahoo.co.uk>
Date: Mon Nov 22 2004 - 17:46:12 CET

New implementation of assert on win32 to fix bug 7936.

Apart from not using sprintf, the new assert is a bit smarter than
the system version. The dialogue has four buttons:

    Debug: break into debugger (== Retry on the old assert)
    Ignore: ignore this time
    Ignore Always: ignore this assert for the rest of the session
    Abort

In addition to the standard file/line info, you are also told how
many times the assert has been encountered.

Couple of things need to be done to fix the different build-systems,
and I would appreciate if someone who uses them could take care of
that:

(a) af/util/win/ needs to be added to the include path for the
resource compiler. For the MSVC project files, for the overall
AbiWord project, this is done under Project->Settings->Resources.
I have made the necessary change for mingw, and my understanding is
that no change should be required for MSVC using the makefiles.

(b) for gcc it might be necessary to tweak ut_assert.h around line 52
to generate the correct inline assembly opcode -- I have followed the
gcc docs, but the code has not been compiled. In any case the code in
ut_assert.h is liberally commented, so should changes be required, it
should be easy todo.

files: ut_assert.h, ut_Win32Misc.cpp, ut_Win32Resources.rc2,
ap/main/win32/Makefile

Tomas
Received on Mon Nov 22 17:44:01 2004

This archive was generated by hypermail 2.1.8 : Mon Nov 22 2004 - 17:44:01 CET