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

Make Class no longer implement Message directly #155

Merged
merged 1 commit into from
Jun 6, 2022
Merged

Conversation

madsmtm
Copy link
Owner

@madsmtm madsmtm commented Jun 6, 2022

Blocked on #150.

This is changed so that:

  • Id<T, O> is correct for all T: Message (currently Id<Class, O> is possible).
  • ClassBuilder::add_method doesn't accept functions that take &Class as the receiver.

Closes #66 as this is IMO the better alternative (causes less churn and confusion about a lot of different traits).

@madsmtm madsmtm added bug Something isn't working A-objc2 Affects the `objc2`, `objc2-exception-helper` and/or `objc2-encode` crates labels Jun 6, 2022
@madsmtm madsmtm added this to the objc2 v0.3 milestone Jun 6, 2022
@madsmtm madsmtm force-pushed the class-not-message branch from 87bb19f to ce8393d Compare June 6, 2022 16:15
@madsmtm madsmtm force-pushed the msg-send-receiver-soundness branch 3 times, most recently from 7a94811 to 2beef61 Compare June 6, 2022 16:58
Base automatically changed from msg-send-receiver-soundness to master June 6, 2022 18:27
This is done so that:
- `Id<T, O>` is correct for all `T: Message` (currently `Id<Class, _>` is possible).
- `ClassBuilder::add_method` doesn't accept functions that take `&Class` as the receiver.
@madsmtm madsmtm force-pushed the class-not-message branch from ce8393d to 9bd6cc4 Compare June 6, 2022 18:34
@madsmtm madsmtm merged commit ee5948e into master Jun 6, 2022
@madsmtm madsmtm deleted the class-not-message branch June 6, 2022 19:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-objc2 Affects the `objc2`, `objc2-exception-helper` and/or `objc2-encode` crates bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant