Преглед изворни кода

added DISALLOW_COPY_AND_ASSIGN macro

bunnei пре 12 година
родитељ
комит
925a894c1b
1 измењених фајлова са 5 додато и 0 уклоњено
  1. 5 0
      src/common/src/common.h

+ 5 - 0
src/common/src/common.h

@@ -163,4 +163,9 @@ enum EMUSTATE_CHANGE
     EMUSTATE_CHANGE_STOP
 };
 
+// This should be used in the private: declarations for a class
+#define DISALLOW_COPY_AND_ASSIGN(TypeName) \
+    TypeName(const TypeName&);               \
+    void operator=(const TypeName&)
+
 #endif // _COMMON_H_