Static scan
Static Analysis
1, can be in the coding phase, the development of self-code inspection. Early detection of code pitfalls.
2, directly analyze the source code to find errors in the program, without the need to actually run.
3. Automatic detection of bugs in objective-c programs, memory leaks and other problems.
4. The sooner the memory problem is discovered, the smaller the cost of the solution.
Static Scan method : Xcode integration Tool
Under Xcode, for a project, click Product--analyze on the menu bar;
650) this.width=650; "src=" Http://note.youdao.com/yws/res/392/FE702D4198FD4EBAAB7D90B0E613A1E4 "alt=" Image_ 20151103173740.png "style=" border:0px; "/>
Scan Results Analysis
Scan results include warning and error list, you can click in the prompt to see the corresponding suspicious code;
650) this.width=650; "src=" http://note.youdao.com/yws/res/396/A502DC5886D1401893F426C2CD1DD7E0 "alt=" unnamed. png " Style= "border:0px;"/>
Problem classification:
Dead Store
Memory
Memory Error
Core Foundation
Logic Error
API Misuse
Points to focus on:
Memory------the point of leakage;
Static Scan Usage Scenarios:
1, in the development of the coding stage, the direct analysis of the source code to find errors in the program, without the need to actually run, early detection of hidden code.
2, test in the smoke test can be scanned first, error too much code modification too large cases can be temporarily not involved in testing, so as not to cause rework.
White box 1:ios static code scan