Martin Vermeer <[EMAIL PROTECTED]> writes:

Ok, these seems simple enough, but why are they needed?

| Index: src/graph.C
| ===================================================================
| RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/graph.C,v
| retrieving revision 1.10
| diff -u -p -r1.10 graph.C
| --- src/graph.C       8 Sep 2003 09:51:40 -0000       1.10
| +++ src/graph.C       2 Oct 2003 13:49:12 -0000
| @@ -173,7 +173,7 @@ Graph::getPath(int from, int t)
|               path.push_back(prev_edge[t]);
|               t = prev_vertex[t];
|       }
| -     reverse(path.begin(), path.end());
| +     std::reverse(path.begin(), path.end());
|       return path;
|  }

Are there no "using std::reverse" at the top of the file? There must
be some lookup issues. But why does this monster raise its head now?
this code has been unchanged for some time?

Anyhow, the change is nice enough. Either this or a "using
std::reverse"
  
| Index: src/lyx_main.C
| ===================================================================
| RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/lyx_main.C,v
| retrieving revision 1.177
| diff -u -p -r1.177 lyx_main.C
| --- src/lyx_main.C    26 Sep 2003 14:27:19 -0000      1.177
| +++ src/lyx_main.C    2 Oct 2003 13:49:12 -0000
| @@ -76,12 +76,13 @@ using std::endl;
|  
|  using std::vector;
|  
| +#if 0
|  #ifndef CXX_GLOBAL_CSTD
|  using std::exit;
|  using std::signal;
|  using std::system;
|  #endif
| -
| +#endif
|  
|  extern void QuitLyX();

We need to find out why this is needed, it shouldn't be.
  
| Index: src/paragraph_pimpl.C
| ===================================================================
| RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/paragraph_pimpl.C,v
| retrieving revision 1.84
| diff -u -p -r1.84 paragraph_pimpl.C
| --- src/paragraph_pimpl.C     16 Sep 2003 14:08:05 -0000      1.84
| +++ src/paragraph_pimpl.C     2 Oct 2003 13:49:13 -0000
| @@ -274,7 +274,7 @@ void Paragraph::Pimpl::insertChar(pos_ty
|  
|       // Update the font table.
|       FontTable search_font(pos, LyXFont());
| -     for (FontList::iterator it = lower_bound(fontlist.begin(),
| +     for (FontList::iterator it = std::lower_bound(fontlist.begin(),
|                                                     fontlist.end(),
|                                                     search_font, matchFT());
|            it != fontlist.end(); ++it)
| @@ -319,7 +319,7 @@ void Paragraph::Pimpl::eraseIntern(pos_t
|       FontTable search_font(pos, LyXFont());
|  
|       FontList::iterator it =
| -             lower_bound(fontlist.begin(),
| +             std::lower_bound(fontlist.begin(),
|                           fontlist.end(),
|                           search_font, matchFT());
|       if (it != fontlist.end() && it->pos() == pos &&

I see that we have a "using std::upper_bound", we should just add a
"using std::lower_bound" as well.

| Index: src/mathed/math_cursor.C
| ===================================================================
| RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/mathed/math_cursor.C,v
| retrieving revision 1.359
| diff -u -p -r1.359 math_cursor.C
| --- src/mathed/math_cursor.C  30 Sep 2003 07:58:03 -0000      1.359
| +++ src/mathed/math_cursor.C  2 Oct 2003 13:49:14 -0000
| @@ -36,7 +36,9 @@
|  //#define FILEDEBUG 1
|  
|  using std::endl;
| +#ifndef CXX_GLOBAL_CSTD
|  using std::isalpha;
| +#endif
|  using std::min;
|  using std::swap;

ok.
  
| Index: src/mathed/math_parser.C
| ===================================================================
| RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/mathed/math_parser.C,v
| retrieving revision 1.291
| diff -u -p -r1.291 math_parser.C
| --- src/mathed/math_parser.C  9 Sep 2003 17:25:33 -0000       1.291
| +++ src/mathed/math_parser.C  2 Oct 2003 13:49:14 -0000
| @@ -65,7 +65,9 @@ following hack as starting point to writ
|  #include "support/std_sstream.h"
|  #include "debug.h"
|  
| +#ifndef CXX_GLOBAL_CSTD
|  using std::atoi;
| +#endif
|  using std::endl;
|  using std::fill;

ok
  
| Index: src/mathed/math_sizeinset.C
| ===================================================================
| RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/mathed/math_sizeinset.C,v
| retrieving revision 1.40
| diff -u -p -r1.40 math_sizeinset.C
| --- src/mathed/math_sizeinset.C       8 Sep 2003 00:33:40 -0000       1.40
| +++ src/mathed/math_sizeinset.C       2 Oct 2003 13:49:14 -0000
| @@ -17,7 +17,9 @@
|  #include "math_streamstr.h"
|  #include "support/std_ostream.h"
|  
| +#ifndef CXX_GLOBAL_CSTD
|  using std::atoi;
| +#endif
|  
|  using std::auto_ptr;

ok
  
| Index: src/mathed/math_streamstr.C
| ===================================================================
| RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/mathed/math_streamstr.C,v
| retrieving revision 1.17
| diff -u -p -r1.17 math_streamstr.C
| --- src/mathed/math_streamstr.C       5 Sep 2003 16:18:57 -0000       1.17
| +++ src/mathed/math_streamstr.C       2 Oct 2003 13:49:14 -0000
| @@ -12,7 +12,7 @@
|  
|  #include "math_streamstr.h"
|  #include "math_mathmlstream.h"
| -
| +#include "support/std_ostream.h"
|  
|  WriteStream & operator<<(WriteStream & ws, string const & s)
|  {

What are the errors when std_ostream.h are left out?
but this change is ok.

| Index: src/support/lstrings.C
| ===================================================================
| RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/support/lstrings.C,v
| retrieving revision 1.80
| diff -u -p -r1.80 lstrings.C
| --- src/support/lstrings.C    25 Sep 2003 23:01:43 -0000      1.80
| +++ src/support/lstrings.C    2 Oct 2003 13:49:14 -0000
| @@ -20,6 +20,7 @@
|  #include "tostr.h"
|  
|  #include <boost/tokenizer.hpp>
| +#include <boost/assert.hpp>
|  
|  #include <algorithm>

what are the errors? (and why do we not see them with gcc 3.x?)

but ok.  

-- 
        Lgb

Reply via email to