objc2
objc2 copied to clipboard
WIP on desired `bindgen` output
Progress on evaluating if and/or how we should do #85.
Don't look too much at the objc2-foundation-sys
stuff, the idea is that that part would be automatically generated - rather, focus on objc2-foundation
, and think about whether using the bindings is better or worse.
Another random idea: Add a new macro that makes it possible to still use the "familiar" msg_send!
syntax:
msg_send_2![self, getObjects: vec.as_ptr(), range: range]
// ->
self.getObjects_range_(vec.as_ptr(), range)
This would require the paste
macro.
The biggest problem I had with this approach was that the separation between a sys
crate and a "Rusty" crate lead to a lot of unnecessary duplication - and you're effectively always going to just be using the sys
crate since we can't possibly hope to make "Rusty" bindings for all of Foundation/AppKit.
Future work in this problem space is happening in https://github.com/madsmtm/objc2/pull/264