forum

Home / DeveloperSection / Forums / performSelector may cause a leak because its selector is unknown

performSelector may cause a leak because its selector is unknown

Anonymous User 2163 25-Apr-2015
I'm getting the following warning by the ARC compiler:
"performSelector may cause a leak because its selector is unknown".
Here's what I'm doing:
[_controller performSelector:NSSelectorFromString(@"someMethod")];
Why do I get this warning? I understand the compiler can't check if the selector exists or not, but why would that cause a leak? And how can I change my code so that I don't get this warning anymore?

Updated on 25-Apr-2015
I am a content writter !

Can you answer this question?


Answer

1 Answers

Liked By