1.TARGETS --->build settings 搜索 compiler
找到 compiler for c/c++/objective-c 改成 APPLE LLVM compiler 3.0
2.TARGETS --->build settings 搜索 analyzer
Run Static Analyzer 改成 YES
3.TARGETS --->build settings 搜索 automatic
objective-c Automatic Reference Counting 改成YES
4.From Xcode's menu
Edit\Refactor\Convert to Objective-C ARC.
5.Open the Xcode Preferences window (from the menubar, under Xcode) and go to the General tab.
Enable the option Continue building after errors:
6.修改代码
eg.
- (void)onHelpViewAnimationComplete:(NSString *)animationID finished:(NSNumber *)finished context:(void *)context { UIImageView *imageView = (__bridge UIImageView *)context; [imageView removeFromSuperview]; helpView = nil;}
eg.
[UIView beginAnimations:nil context:(__bridge void *)helpView];