added some #ifdef logic to allow me to turn NEW_STRING_APIS off, so I can continue to profile for bloat; added an implementation specific |operator+()| to resolve ambiguity with promises on some platforms

git-svn-id: svn://10.0.0.236/trunk@71988 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
scc%mozilla.org
2000-06-11 04:35:02 +00:00
parent 0b43b3b7d8
commit bb796c096f
3 changed files with 42 additions and 0 deletions

View File

@@ -42,6 +42,11 @@
#define NEW_STRING_APIS 1
#endif //NEW_STRING_APIS
// Need this to enable comparison profiling for a while
#ifdef OLD_STRING_APIS
#undef NEW_STRING_APIS
#endif
#ifndef _nsCString_
#define _nsCString_
@@ -796,6 +801,15 @@ private:
void InsertWithConversion( char, PRUint32 );
};
#ifdef NEW_STRING_APIS
inline
nsPromiseConcatenation<char>
operator+( const nsPromiseConcatenation<char>& lhs, const nsCString& rhs )
{
return nsPromiseConcatenation<char>(lhs, rhs);
}
#endif
#ifdef NEW_STRING_APIS
NS_DEF_STRING_COMPARISON_OPERATORS(nsCString, char)
NS_DEF_DERIVED_STRING_OPERATOR_PLUS(nsCString, char);