I use in my application QHTTPOperation.{h/m} found here all work properly but I got 8 warnings as follow:
Writable atomic property ‘acceptableStatusCodes’ cannot pair a
synthesized setter/getter with a user defined setter/getterWritable atomic property ‘acceptableContentTypes’ cannot pair a
synthesized setter/getter with a user defined setter/getterWritable atomic property ‘authenticationDelegate’ cannot pair a
synthesized setter/getter with a user defined setter/getter…
I am asking because I have noticed that in the project of the above link there is no Warnings related to QHTTPOperation.{h/m}.
Any idea?
Thanks
declare the property
nonatomic.because the compiler does not verify a user-defined accessor’s implementation is atomic or nonatomic, it assumes it is not atomic. this is a pretty safe assumption considering the actual implementation uses object level spin locks (in some cases), and the data which backs the implementation is abstracted from us. the only way we could fulfill the contact is by using the (private) runtime functions which the compiler uses, and then the compiler would have to verify the calls and parameters were correct in this scenario. thus, the user-defined accessor is not guaranteed to fulfill the standard objc runtime atomic contract.