]> git.lyx.org Git - features.git/commitdiff
compilation fix when assertions are disabled
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Mon, 7 Mar 2005 11:03:45 +0000 (11:03 +0000)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Mon, 7 Mar 2005 11:03:45 +0000 (11:03 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9697 a592a061-630c-0410-9148-cb99ea01b6c8

src/ChangeLog
src/dociterator.C
src/lyxfunc.C
src/text3.C

index 9fa0b2249e6e9cde98dd648687ccfe91b8878ad2..ad2272deef392f6dc3c3498bfa748766552223f3 100644 (file)
@@ -1,3 +1,12 @@
+2005-03-07  Jean-Marc Lasgouttes  <lasgouttes@lyx.org>
+
+       * lyxfunc.C (getStatus): fix warning when assertions are disabled
+
+       * text3.C: 
+       * lyxfunc.C: 
+       * dociterator.C: include <boost/current_function.hpp>, which is
+       needed when assertions are disabled.
+
 2005-03-05  Johnathan Burchill  <jkerrb@users.sourceforge.net> 
 
        * text2.C: fix for stuck cursor when traversing two 
index 74c5aa38a6b510c4f547c3a62e00fe3040151509..76de0484dcd300129aaeabc87413ae15af9f5567 100644 (file)
@@ -22,6 +22,7 @@
 #include "mathed/math_inset.h"
 
 #include <boost/assert.hpp>
+#include <boost/current_function.hpp>
 
 using std::endl;
 
index f6e54aa3faf682d4d37af6ac964aedb5cdc7c024..cae053cfa5a2300fe9f136f21e1582597f27a167 100644 (file)
@@ -90,6 +90,7 @@
 #include "support/convert.h"
 #include "support/os.h"
 
+#include <boost/current_function.hpp>
 #include <boost/filesystem/operations.hpp>
 
 #include <sstream>
@@ -156,17 +157,9 @@ bool getStatus(LCursor cursor,
        bool res = false;
        for ( ; cursor.depth(); cursor.pop()) {
                //lyxerr << "\nLCursor::getStatus: cmd: " << cmd << endl << *this << endl;
-               DocIterator::idx_type & idx = cursor.idx();
-               DocIterator::idx_type const lastidx = cursor.lastidx();
-               BOOST_ASSERT(idx <= lastidx);
-
-               DocIterator::pit_type & pit = cursor.pit();
-               DocIterator::pit_type const lastpit = cursor.lastpit();
-               BOOST_ASSERT(pit <= lastpit);
-
-               DocIterator::pos_type & pos = cursor.pos();
-               DocIterator::pos_type const lastpos = cursor.lastpos();
-               BOOST_ASSERT(pos <= lastpos);
+               BOOST_ASSERT(cursor.idx() <= cursor.lastidx());
+               BOOST_ASSERT(cursor.pit() <= cursor.lastpit());
+               BOOST_ASSERT(cursor.pos() <= cursor.lastpos());
 
                // The inset's getStatus() will return 'true' if it made
                // a definitive decision on whether it want to handle the
index 5fb9e0ddcabb84ea224ec029ce3445020055e716..ca407c628ff191d0321fb718c3aef7fc87bea2ac 100644 (file)
@@ -61,6 +61,8 @@
 #include "mathed/math_hullinset.h"
 #include "mathed/math_macrotemplate.h"
 
+#include <boost/current_function.hpp>
+
 #include <clocale>
 #include <sstream>