Objective-C 樣式檢查器:ocstyle
ocstyle 是一個用 Python 開發的 Objective-C 樣式檢查器。例如你有一個源碼文件 test.m:
+(void) someMessage:(NSString*)subdomain { NSString *ShouldStartLowerCase; // ... }使用 ocstyle 檢查的結果是:
$ ocstyle test.m test.m ERROR: 1:1 [1] - MissingSpace - Expected 1, got 0 ERROR: 1:8 [8] - ExtraSpace - Did not expect ' ' here ERROR: 1:29 [29] - MissingSpace - Expected 1, got 0 ERROR: 1:41 [41] - MissingNewline - Should have newline after ; ERROR: 1:41 [41] - MissingSemicolon - Expected a semicolon ERROR: 2:35 [77] - BadLocalVariableName - Local variable must start with a lower case letter
本文由用戶 jopen 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!