aboutsummaryrefslogtreecommitdiff
path: root/src/fstring.h
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2008-09-11 21:09:31 +0000
committerMike Buland <eichlan@xagasoft.com>2008-09-11 21:09:31 +0000
commit7ddeaa42e452a85e275649efa519fe0959210d12 (patch)
treeee83a1a5b8855d11855698ccd68b19241b3ec40d /src/fstring.h
parent5dbc8f155b16759b4ebb82aceb3759c686489e3b (diff)
downloadlibbu++-7ddeaa42e452a85e275649efa519fe0959210d12.tar.gz
libbu++-7ddeaa42e452a85e275649efa519fe0959210d12.tar.bz2
libbu++-7ddeaa42e452a85e275649efa519fe0959210d12.tar.xz
libbu++-7ddeaa42e452a85e275649efa519fe0959210d12.zip
Fixed some whacky old FBasicString hikinx. Basically it supports all the basic,
expected operators now, like plus. It was annoying without them.
Diffstat (limited to '')
-rw-r--r--src/fstring.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/fstring.h b/src/fstring.h
index fb4bf55..93216a1 100644
--- a/src/fstring.h
+++ b/src/fstring.h
@@ -492,6 +492,20 @@ namespace Bu
492 return (*this); 492 return (*this);
493 } 493 }
494 494
495 MyType operator +( const MyType &rRight )
496 {
497 MyType ret( *this );
498 ret.append( rRight );
499 return ret;
500 }
501
502 MyType operator +( const chr *pRight )
503 {
504 MyType ret( *this );
505 ret.append( pRight );
506 return ret;
507 }
508
495 /** 509 /**
496 * Reset your FString to this character array. 510 * Reset your FString to this character array.
497 *@param pData (const chr *) The character array to set your FString to. 511 *@param pData (const chr *) The character array to set your FString to.
@@ -1032,6 +1046,12 @@ namespace Bu
1032 1046
1033 template<> uint32_t __calcHashCode<FString>( const FString &k ); 1047 template<> uint32_t __calcHashCode<FString>( const FString &k );
1034 template<> bool __cmpHashKeys<FString>( const FString &a, const FString &b ); 1048 template<> bool __cmpHashKeys<FString>( const FString &a, const FString &b );
1049 template<class T> FBasicString<T> operator +( const T *pLeft, const FBasicString<T> &rRight )
1050 {
1051 Bu::FBasicString<T> ret( pLeft );
1052 ret.append( rRight );
1053 return ret;
1054 }
1035 1055
1036#ifdef BU_TRACE 1056#ifdef BU_TRACE
1037 template<> void __tracer_format<FString>( const FString &v ); 1057 template<> void __tracer_format<FString>( const FString &v );