Andre Poenitz wrote:
On Tue, Apr 15, 2008 at 05:26:20PM -0000, [EMAIL PROTECTED] wrote:
Author: younes
Date: Tue Apr 15 19:26:19 2008
New Revision: 24275

URL: http://www.lyx.org/trac/changeset/24275
Log:
Release compile fix.

Modified:
    lyx-devel/trunk/src/Text3.cpp

Modified: lyx-devel/trunk/src/Text3.cpp
URL: http://www.lyx.org/trac/file/lyx-devel/trunk/src/Text3.cpp?rev=24275
==============================================================================
--- lyx-devel/trunk/src/Text3.cpp (original)
+++ lyx-devel/trunk/src/Text3.cpp Tue Apr 15 19:26:19 2008
@@ -131,7 +131,9 @@
                const int old_pos = cur.pos();
 #endif
                cur.insert(new InsetMathHull(hullSimple));
+#ifdef ENABLE_ASSERTIONS
                LASSERT(old_pos == cur.pos(), /**/);
+#endif
                cur.nextInset()->edit(cur, true);
                // don't do that also for LFUN_MATH_MODE
                // unless you want end up with always changing


Huh?

Is this time-critical?

The diff is misleading. This is a compile fix because old_pos definition is enclosed between the same #ifdef:

        if (sel.empty()) {
#ifdef ENABLE_ASSERTIONS
                const int old_pos = cur.pos();
#endif
                cur.insert(new InsetMathHull(hullSimple));
#ifdef ENABLE_ASSERTIONS
                LASSERT(old_pos == cur.pos(), /**/);
#endif


I am not sure this assertion is worth anything anyway.

Abdel.

Reply via email to