在開發過程中,我經常需要多個嵌套多行(或「部分行」)註釋。在Xcode中禁用「/ *塊內註釋」警告
Xcode最近推出了可能是世界上最煩人的警告 - 它迫使我禁用「警告作爲錯誤」。我猜這個警告是要捕捉極端罕見的情況,當有人輸入錯誤並導致塊註釋無法結束時 - 但IME還有許多其他問題會導致它很快顯示出來。
一些例子:
/* removed while debugging the BARFOO
-(void) aMethod
{
[self methodCall:7.0 /* needed to FOO the BAR: */ * self.multiplier * /* double for hi-res:*/ 2.0];
}
*/
和:
/* removed while debugging the BARFOO
/** This method has DOCUMENTATION
*/
-(void) aDocumentedMethod
{
...
}
-(void) aMethod
{
/** internally, we have to BAR BAR the FOOFOO.
1. BAR
2. BARBAR
3. Finally, FOOOFOO
*/
...complex lines of source here...
}
*/
,當然還有,非常簡單而調試的雙帶註釋的。
但我不能找到Xcode5地方禁用此警告? - 它似乎並沒有在任何上市警告:(中存在
[XCode的警告: 「/ \ *塊註釋中」]的可能的複製(http://stackoverflow.com/questions/14774127/xcode-warning-within-block-comment) – vaxquis