From addca63bba3ddaf212e44cdf16e95038b0a5bf3e Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Sat, 20 Oct 2007 17:59:32 +0000 Subject: Just marked Bu::FString::c_str as deprecated, don't use it, it'll go away later. --- src/tests/fstratsptr.cpp | 4 ++-- src/tests/fstring.cpp | 9 +++++---- 2 files changed, 7 insertions(+), 6 deletions(-) (limited to 'src/tests') diff --git a/src/tests/fstratsptr.cpp b/src/tests/fstratsptr.cpp index 343f682..61c20bd 100644 --- a/src/tests/fstratsptr.cpp +++ b/src/tests/fstratsptr.cpp @@ -22,8 +22,8 @@ void Swap(PersonPtr one, PersonPtr two) printf( "%s %s\n", - three->sFirstName->c_str(), - three->sLastName->c_str() ); + three->sFirstName->getStr(), + three->sLastName->getStr() ); } int main() diff --git a/src/tests/fstring.cpp b/src/tests/fstring.cpp index 11f147d..d20309a 100644 --- a/src/tests/fstring.cpp +++ b/src/tests/fstring.cpp @@ -27,13 +27,14 @@ Bu::FString genThing() bob += "cd "; bob += "efg"; - printf("---bob------\n%08X: %s\n", (unsigned int)bob.c_str(), bob.c_str() ); + printf("---bob------\n%08X: %s\n", (unsigned int)bob.getStr(), + bob.getStr() ); return bob; } void thing( Bu::FString str ) { - printf("Hey: %s\n", str.c_str() ); + printf("Hey: %s\n", str.getStr() ); } void copyfunc( std::string temp ) @@ -107,7 +108,7 @@ void doTimings() delete[] buf; } -#define pem printf("---------\n%08X: %s\n%08X: %s\n", (unsigned int)str.c_str(), str.c_str(), (unsigned int)str2.c_str(), str2.c_str() ); +#define pem printf("---------\n%08X: %s\n%08X: %s\n", (unsigned int)str.getStr(), str.getStr(), (unsigned int)str2.getStr(), str2.getStr() ); int main( int argc, char *argv ) { Bu::FString fs1; @@ -137,7 +138,7 @@ int main( int argc, char *argv ) thing( str2 ); thing("test."); - printf("%d == %d\n", Bu::__calcHashCode( str ), Bu::__calcHashCode( str.c_str() ) ); + printf("%d == %d\n", Bu::__calcHashCode( str ), Bu::__calcHashCode( str.getStr() ) ); doTimings(); } -- cgit v1.2.3