You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you use method_setImplementation(Method, IMP) on a method retrieved from a metaclass (lit.: a class method), and that metaclass is fully resolved, its dtable will not be updated to point to the new IMP.
This is due to a bug in objc_updateDtableForClassContainingMethod. It iterates over every class known to the runtime and updates the dtable of the first class containing that selector (!!).
The text was updated successfully, but these errors were encountered:
DHowett-MSFT
changed the title
[libobjc2] method_replaceImplementation does not work on resolved metaclasses
[libobjc2] method_setImplementation does not work on resolved metaclasses
Jan 5, 2017
When you use
method_setImplementation(Method, IMP)
on a method retrieved from a metaclass (lit.: a class method), and that metaclass is fully resolved, its dtable will not be updated to point to the new IMP.This is due to a bug in objc_updateDtableForClassContainingMethod. It iterates over every class known to the runtime and updates the dtable of the first class containing that selector (!!).
The text was updated successfully, but these errors were encountered: