naming policy, container class issue

naming policy, container class issue
0.0 0


naming policy suggestion:
According to development doc by Apple(, methods’ name start with “alloc”, “new”, “copy”, or “mutableCopy” means the caller of those methods takes the ownership the object. Cocos2d-x CCObject adopts convention that method starting with “create” creates autorelease object whereas “create” may have the same meaning as “alloc” or “new”. So why not use “instance” instead of “create” to indicate an auto-release object.

container classes:
Cocos2d-x’s container classes (CCArray, CCSet) behaves differently from what expected, for example: the following code will not produce set: (element1, element3, element4) as it uses pointer based comparing rather than real value based.

CCSet *testSet = CCSet::create();