Can I subclass an ARC class other than ARC

I want to subclass a class called "ASIFormDataRequest", which is in my target program with the compiler flag "-fno-objc-arc". Can I create a subclass of this class that uses ARC without problems?

Xcode does not cause any errors if I do this. Any thoughts?

Thanks Lars

+4
source share
1 answer

This should not be a problem. The way to think about ARC is that there is no difference between an ARC file and a file other than ARC after compiling it (since all compilers execute retain , release and autorelease in the appropriate places), and since each file is compiled separately before they will be related to each other, the resulting compiled code will be the same (apart from certain optimizations that the compiler can do when it deals with ARC code).

+6
source

Source: https://habr.com/ru/post/1379671/


All Articles