summaryrefslogtreecommitdiff
path: root/Ivy
diff options
context:
space:
mode:
authorfcolin2007-02-01 13:04:22 +0000
committerfcolin2007-02-01 13:04:22 +0000
commit7bbc8b43b4901cd8cddb5a8cd0cc2246d4f45529 (patch)
tree37b745994df01376b37a777b074420d5bcc69788 /Ivy
parent2463a4b909e35d2312bdffbae124e3edc542cc8c (diff)
downloadivy-cplusplus-7bbc8b43b4901cd8cddb5a8cd0cc2246d4f45529.zip
ivy-cplusplus-7bbc8b43b4901cd8cddb5a8cd0cc2246d4f45529.tar.gz
ivy-cplusplus-7bbc8b43b4901cd8cddb5a8cd0cc2246d4f45529.tar.bz2
ivy-cplusplus-7bbc8b43b4901cd8cddb5a8cd0cc2246d4f45529.tar.xz
Utilisateur : Fcolin Date : 31/01/01 Heure : 11:18 Archivé dans $/Ivy (vss 5)
Diffstat (limited to 'Ivy')
-rw-r--r--Ivy/Regexp.cxx32
1 files changed, 16 insertions, 16 deletions
diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx
index 01f3d45..ebade4e 100644
--- a/Ivy/Regexp.cxx
+++ b/Ivy/Regexp.cxx
@@ -219,7 +219,7 @@ enum {
class CRegErrorHandler
{
friend Regexp;
- mutable String m_szError;
+ mutable string m_szError;
static const char * FindErr( int id );
protected:
void ClearErrorString() const;
@@ -229,7 +229,7 @@ public:
CRegErrorHandler() { }
CRegErrorHandler( const CRegErrorHandler & reh ) : m_szError( reh.m_szError ) {}
- const String & GetErrorString() const;
+ const string & GetErrorString() const;
};
void CRegErrorHandler::regerror( const char * s ) const
@@ -243,7 +243,7 @@ void CRegErrorHandler::regerror( int id ) const
regerror( FindErr( id ) );
}
-const String & CRegErrorHandler::GetErrorString() const
+const string & CRegErrorHandler::GetErrorString() const
{
return m_szError;
}
@@ -324,7 +324,7 @@ public:
bool regexec( const char * string );
bool Status() const { return status; }
- String GetReplaceString( const char* sReplaceExp ) const;
+ string GetReplaceString( const char* sReplaceExp ) const;
regexp * getCopy();
@@ -333,8 +333,8 @@ public:
#endif
#ifdef _DEBUG
- String m_originalPattern;
- String m_modifiedPattern;
+ string m_originalPattern;
+ string m_modifiedPattern;
#endif
};
@@ -1035,7 +1035,7 @@ class CRegExecutor : public CRegProgramAccessor
{
friend bool regexp::regexec( const char * str );
- char * reginput; // String-input pointer.
+ char * reginput; // string-input pointer.
char * regbol; // Beginning of input, for ^ check.
char * * regstartp; // Pointer to startp array.
char * * regendp; // Ditto for endp.
@@ -1535,7 +1535,7 @@ bool Regexp::Match( const char * s )
return ret;
}
-String Regexp::GetReplaceString( const char * source ) const
+string Regexp::GetReplaceString( const char * source ) const
{
ClearErrorString();
if ( rc )
@@ -1603,18 +1603,18 @@ int Regexp::safeIndex( unsigned int i ) const
return i < Regexp::NSUBEXP ? i : Regexp::NSUBEXP;
}
-const String Regexp::operator[]( unsigned int i ) const
+const string Regexp::operator[]( unsigned int i ) const
{
- String value;
+ string value;
ClearErrorString();
- assert( rc );
+ ASSERT( rc );
if ( rc )
{
int len = SubLength(i);
//char * szbuf = buffer.GetBufferSetLength( len );
//memcpy( szbuf, rc->startp[i], len * sizeof(char) );
//buffer.ReleaseBuffer();
- value = std::string ( rc->startp[i], len );
+ value = string ( rc->startp[i], len );
}
else
{
@@ -1650,9 +1650,9 @@ void regexp::ignoreCase( const char * in, char * out )
// GetReplaceString - Converts a replace expression to a string
// - perform substitutions after a regexp match
// Returns - The resultant string
-String regexp::GetReplaceString( const char* sReplaceExp ) const
+string regexp::GetReplaceString( const char* sReplaceExp ) const
{
- String szEmpty( "" );
+ string szEmpty( "" );
char *src = (char *)sReplaceExp;
//char *buf;
@@ -1698,7 +1698,7 @@ String regexp::GetReplaceString( const char* sReplaceExp ) const
}
}
- String szReplace;
+ string szReplace;
//buf = szReplace.GetBufferSetLength( replacelen );
@@ -1741,7 +1741,7 @@ String regexp::GetReplaceString( const char* sReplaceExp ) const
return szReplace;
}
-String Regexp::GetErrorString() const
+string Regexp::GetErrorString() const
{
// make sure that if status == 0 that we have an error string
//assert( ( ! CompiledOK() ) ? ( rc ? rc->GetErrorString() : m_szError).length() != 0 : 1 );