From ea575235ff3f2029061c0bfc5de2e452490d1d43 Mon Sep 17 00:00:00 2001 From: fcolin Date: Thu, 1 Feb 2007 13:04:32 +0000 Subject: Utilisateur : Fcolin Date : 23/09/05 Heure : 15:27 Archivé dans $/Bus/Ivy Commentaire: (vss 10) --- Ivy/Regexp.cxx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'Ivy') diff --git a/Ivy/Regexp.cxx b/Ivy/Regexp.cxx index 4ba60e3..5916ec8 100644 --- a/Ivy/Regexp.cxx +++ b/Ivy/Regexp.cxx @@ -1556,10 +1556,10 @@ int Regexp::SubStrings() const return ret; } -int Regexp::SubStart( unsigned int i ) const +size_t Regexp::SubStart( size_t i ) const { ClearErrorString(); - int ret = -1; + size_t ret = -1; if ( rc ) ret = rc->startp[safeIndex(i)] - str; else @@ -1567,10 +1567,10 @@ int Regexp::SubStart( unsigned int i ) const return ret; } -int Regexp::SubLength( unsigned int i ) const +size_t Regexp::SubLength( size_t i ) const { ClearErrorString(); - int ret = -1; + size_t ret = -1; if ( rc ) { i = safeIndex(i); @@ -1598,19 +1598,19 @@ void Regexp::Dump() } #endif -int Regexp::safeIndex( unsigned int i ) const +size_t Regexp::safeIndex( size_t i ) const { return i < Regexp::NSUBEXP ? i : Regexp::NSUBEXP; } -const ivy::string Regexp::operator[]( unsigned int i ) const +const ivy::string Regexp::operator[]( size_t i ) const { ivy::string value; ClearErrorString(); ASSERT( rc ); if ( rc ) { - int len = SubLength(i); + size_t len = SubLength(i); //char * szbuf = buffer.GetBufferSetLength( len ); //memcpy( szbuf, rc->startp[i], len * sizeof(char) ); //buffer.ReleaseBuffer(); @@ -1672,7 +1672,7 @@ ivy::string regexp::GetReplaceString( const char* sReplaceExp ) const } // First compute the length of the string - int replacelen = 0; + size_t replacelen = 0; while ((c = *src++) != '\0') { if (c == '&') -- cgit v1.1