- Timestamp:
- Nov 17, 2005, 12:01:45 PM (19 years ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/defs/compiler.h
r3860 r5626 8 8 #endif 9 9 10 #define likely(x) __builtin_expect((x),1) 11 #define unlikely(x) __builtin_expect((x),0) 12 13 #ifdef __unix__ 14 15 // deprecated // 16 #define __LIKELY_IF(condition) if( likely(condition)) 17 #define __UNLIKELY_IF(condition) if( unlikely(condition)) 18 #else 19 #define __LIKELY_IF(condition) if( condition) 20 #define __UNLIKELY_IF(condition) if( condition) 21 #endif 10 #define likely(x) __builtin_expect((x),1) 11 #define unlikely(x) __builtin_expect((x),0) 22 12 23 13 -
trunk/src/lib/lang/base_object.cc
r5513 r5626 137 137 } 138 138 139 /** 140 * compares the ObjectName with an external name 141 * @param objectName: the name to check. 142 * @returns true on match, false otherwise. 143 */ 144 bool BaseObject::operator ==(const char* objectName) 145 { 146 if (likely(this->objectName != NULL && objectName != NULL)) 147 return (strcmp(this->objectName, objectName)) ? false : true; 148 } 149 139 150 140 151 /** -
trunk/src/lib/lang/base_object.h
r5513 r5626 39 39 void whatIs() const; 40 40 41 // 42 bool operator== (const char* objectName); 43 41 44 protected: 42 45 void setClassID(long classID, const char* className);
Note: See TracChangeset
for help on using the changeset viewer.