Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Retrieve class of instance in objc_alloc_init #315

Merged
merged 2 commits into from
Nov 19, 2024
Merged

Conversation

hmelder
Copy link
Collaborator

@hmelder hmelder commented Nov 18, 2024

If +alloc was overwritten, it is not guaranteed that it returns an instance of cls. For example, a class cluster like NSString might return an instance of a subclass instead.
Retrieve the class of the instance returned by objc_alloc instead.

If +alloc was overwritten, it is not guaranteed that it returns an
instance of cls. Retrieve the class of the instance returned by
objc_alloc instead.
@hmelder hmelder merged commit a069727 into master Nov 19, 2024
87 of 89 checks passed
@hmelder hmelder deleted the alloc_init-fixes branch November 19, 2024 12:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants