performSelector may cause a leak because its selector is unknown

后端 未结 19 2235
小蘑菇
小蘑菇 2020-11-22 01:54

I\'m getting the following warning by the ARC compiler:

\"performSelector may cause a leak because its selector is unknown\".

Here\'s what

19条回答
  •  难免孤独
    2020-11-22 02:32

    To ignore the error only in the file with the perform selector, add a #pragma as follows:

    #pragma clang diagnostic ignored "-Warc-performSelector-leaks"
    

    This would ignore the warning on this line, but still allow it throughout the rest of your project.

提交回复
热议问题