]> git.lyx.org Git - lyx.git/blobdiff - src/support/LSubstring.C
lyxserver cleanup patch + andre's small patches
[lyx.git] / src / support / LSubstring.C
index 3b9d1c379255f1d41056bc0c2d19f76b67a2991e..b873c23cf39dad73c58f189b3063c63e33f90436 100644 (file)
@@ -4,7 +4,7 @@
  *           LyX, The Document Processor
  *      
  *           Copyright 1995 Matthias Ettrich
- *           Copyright 1995-2000 The LyX Team.
+ *           Copyright 1995-2001 The LyX Team.
  *
  * ====================================================== */
 
 
 #include "LSubstring.h"
 
+#ifndef CXX_GLOBAL_CSTD
+using std::strlen;
+#endif
+
+
 
 LSubstring::LSubstring(string & s, size_type i, size_type l)
        : ps(&s), pos(i), n(l)
@@ -43,7 +48,7 @@ LSubstring::LSubstring(string & s, string::value_type const * p)
 LSubstring::LSubstring(string & s, LRegex const & r)
        : ps(&s)
 {
-       LRegex::MatchPair res = r.first_match(s);
+       LRegex::MatchPair const res = r.first_match(s);
        if (res.first != string::npos) {
                n = res.second;
                pos = res.first;
@@ -68,14 +73,14 @@ LSubstring & LSubstring::operator=(LSubstring const & s)
 }
 
 
-LSubstring & LSubstring::operator=(char const * p)
+LSubstring & LSubstring::operator=(string::value_type const * p)
 {
        ps->replace(pos, n, p);
        return *this;
 }
 
 
-LSubstring & LSubstring::operator=(char c)
+LSubstring & LSubstring::operator=(string::value_type c)
 {
        ps->replace(pos, n, 1, c);
        return *this;