2012-09-18 47 views
1

一位自由職業者正在爲我開發Iphone應用程序。 該應用程序工作正常,但我在Xcode中加載源代碼時收到37條警告。 你介意快點看看,告訴我是否有一些警告我應該擔心。自由職業者Iphone開發 - Xcode警告是否可以接受?

感謝您的幫助!

yyy Group 
Semantic Issue Group 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/FMDatabase/FMDatabase.m:313:74: Second argument to 'va_arg' is of promotable type 'char'; this va_arg has undefined behavior because arguments will be promoted to 'int' 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/FMDatabase/FMDatabase.m:326:70: Second argument to 'va_arg' is of promotable type 'short'; this va_arg has undefined behavior because arguments will be promoted to 'int' 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/FMDatabase/FMDatabase.m:329:78: Second argument to 'va_arg' is of promotable type 'unsigned short'; this va_arg has undefined behavior because arguments will be promoted to 'int' 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/FMDatabase/FMDatabase.m:350:66: Second argument to 'va_arg' is of promotable type 'float'; this va_arg has undefined behavior because arguments will be promoted to 'double' 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2598:31: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2599:31: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2600:31: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2601:31: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2602:31: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2605:171: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2606:171: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2607:171: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2608:171: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2609:171: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2791:40: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:2802:45: Direct access to objective-c's isa is deprecated in favor of object_setClass() and object_getClass() 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Twitter/SHKTwitter.m:63:17: Receiver type 'int' is not 'id' or interface pointer, consider casting it to 'id' 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Twitter/SHKTwitter.m:63:16: Instance method '-boolValue' not found (return type defaults to 'id') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/UI/SHKFormControllerLargeTextField.m:97:120: Class method '+sharerTitle' not found (return type defaults to 'id') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/UI/SHKFormControllerLargeTextField.m:240:2: Instance method '-sendDidCancel' not found (return type defaults to 'id') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/UI/SHKFormControllerLargeTextField.m:246:5: Instance method '-sendForm:' not found (return type defaults to 'id') 
Format String Issue Group 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/FMDatabase/FMDatabase.m:943:45: Format specifies type 'int' but the argument has type 'long' 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:745:180: Format specifies type 'unsigned long' but the argument has type 'NSUInteger' (aka 'unsigned int') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:746:134: Format specifies type 'unsigned long' but the argument has type 'NSUInteger' (aka 'unsigned int') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:752:98: Format specifies type 'unsigned long' but the argument has type 'NSUInteger' (aka 'unsigned int') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:773:114: Format specifies type 'unsigned long' but the argument has type 'NSUInteger' (aka 'unsigned int') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:786:114: Format specifies type 'unsigned long' but the argument has type 'NSUInteger' (aka 'unsigned int') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/JSONKit/JSONKit.m:795:114: Format specifies type 'unsigned long' but the argument has type 'NSUInteger' (aka 'unsigned int') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Core/Helpers/OAuth/OAMutableURLRequest.m:194:48: Format specifies type 'int' but the argument has type 'time_t' (aka 'long') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Core/SHK.m:523:54: Format specifies type 'int' but the argument has type 'NSTimeInterval' (aka 'double') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Facebook/SHKFacebook.m:87:53: Format specifies type 'int' but the argument has type 'NSTimeInterval' (aka 'double') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Flickr/LFHTTPRequest.m:460:72: Format specifies type 'unsigned long' but the argument has type 'NSUInteger' (aka 'unsigned int') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Flickr/LFHTTPRequest.m:469:72: Format specifies type 'unsigned long' but the argument has type 'NSUInteger' (aka 'unsigned int') 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Google Reader/SHKGoogleReader.m:245:65: Format specifies type 'int' but the argument has type 'NSTimeInterval' (aka 'double') 
Cocoa API Issue Group 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Facebook/FBRequest.m:152:29: Using 'stringWithString:' with a literal is redundant 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Facebook/FBRequest.m:161:29: Using 'stringWithString:' with a literal is redundant 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Twitter/SHKTwitter.m:610:21: Using 'stringWithString:' with a literal is redundant 
/Users/xxx/Desktop/Iphone App/yyy 3/yyy/Classes/ShareKit/Sharers/Services/Vkontakte/SHKVkontakte.m:409:20: Using 'stringWithString:' with a literal is redundant 

回答

5

看來,這些警告大部分來自項目中使用的第三方庫,如JSONKit和ShareKit。儘管我個人身上沒有太大的東西出現在我身上。警告可以在各種版本的Xcode之間產生。

+0

同意各種版本的Xcode產生/不產生警告。我的應用程序可能在Xcode 4.3上無警告,然後在4.5上發出各種警告。事實上,我的一個應用程序就是這樣做的,大部分警告都來自我正在使用的JSON庫(好像是這裏的情況) – MikeS

+0

感謝您的幫助! – user1564140

+0

如果您不需要進一步的答案,請接受答案:) – Brayden

相關問題