标签:style ar for sp bs amp line as tt
第一种方法:
std::list<Entity *> children;
for(auto&& child : children) {
delete child;
}
children.clear();
第二种方法:
std::list<Entity *> children;
for(auto itr = children.begin(); itr != children.end(); ++itr)
{
Entity* child = *itr;
delete child;
}
第三种方法:
std::list<Entity *> children;
for(Entity *ptr : children) {
delete ptr;
}
children.clear();
标签:style ar for sp bs amp line as tt
原文地址:http://www.cnblogs.com/learnopencad/p/4060949.html