Just wondering the reason that CCArray/CCDictionary/etc are created instead of wrapping STL library such as std:vector/std:list
Does it work faster?
CCArray and CCDictionary classes are used to hold most cocos2d-x classes. Both containers have a auto-release mechanism added to it.
In that case, the question is why not to create CCArray and CCDictionary that has a std list of CCObjects instead of pointer list
(https://github.com/cocos2d/cocos2d-x/blob/gles20/cocos2dx/cocoa/CCDictionary.h)
For example,I will write that way
class CC_DLL CCDictionary : public CCObject
{
private:
std::vector m_pElements;
}
It will then be able to extend the class with the help of STL library such as qsort/map/etc