mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 00:01:50 +00:00
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
This commit is contained in:
parent
29d26770c9
commit
1d272d98b9
@ -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);
|
||||
|
@ -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);
|
||||
|
@ -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);
|
||||
|
Loading…
Reference in New Issue
Block a user