HomePhabricator

[objc_direct] Allow for direct messages be sent to `self` when it is a Class
a4b8abe06515Unpublished

Authored by MadCoder on Jan 14 2020, 7:51 PM.

Unpublished Commit ยท Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

[objc_direct] Allow for direct messages be sent to self when it is a Class

Sending a message to self when it is const and within a class method
is safe because we know that self is the Class itself.

We can only relax this warning in ARC.

Signed-off-by: Pierre Habouzit <phabouzit@apple.com>
Radar-Id: rdar://problem/58581965
Differential Revision: https://reviews.llvm.org/D72747
(cherry picked from commit 7596d3c50c4b265612d326369e2a015cf8c60801)