hmmm...backing out my change on unix only to if memcmp() is actually SLOWER

(its faster on windows!)
This commit is contained in:
alecf%netscape.com 2002-08-27 02:56:06 +00:00
parent abb1b442de
commit 94c1d39efc

View File

@ -72,7 +72,15 @@ struct nsID {
*/
inline PRBool Equals(const nsID& other) const {
#ifdef XP_UNIX
return (PRBool)
((((PRUint32*) &m0)[0] == ((PRUint32*) &other.m0)[0]) &&
(((PRUint32*) &m0)[1] == ((PRUint32*) &other.m0)[1]) &&
(((PRUint32*) &m0)[2] == ((PRUint32*) &other.m0)[2]) &&
(((PRUint32*) &m0)[3] == ((PRUint32*) &other.m0)[3]));
#else
return (memcmp(this, &other, sizeof(*this)) == 0);
#endif
}
/**