从superview中删除多个视图

Mc.*_*ver 0 iphone sdk xcode ipad ios

使用此方法时,我需要同时删除多个UIViews表单superview:

[view1 , view 2 , vie3 removeFromSuperview]; 
Run Code Online (Sandbox Code Playgroud)

编译器给了我一个警告:

**warning: Unused Entity Issue: Expression result unused**
Run Code Online (Sandbox Code Playgroud)

怎么做对了?

小智 5

或者,如果要从特定视图中删除所有子视图:

for (UIView *subview in view.subviews) {
    [subview removeFromSuperview];
}
Run Code Online (Sandbox Code Playgroud)