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
functions: Add support for functions #193
base: main
Are you sure you want to change the base?
Conversation
Based on current state:
|
I have only really implemented it for RefType -- I defaulted to the objc impl but I can put in "not implemented" instead.
Ha, no are accidental.
Suggestion for the short term?
Yeah I have that rule in there constraining what is generated just for testing purposes, probably better to add in skipping when we know we'll fail but I need to explore more, any input on approach welcomed. |
Use Since functions are simple symbol names, they could be added to the blacklist in Also maybe for now just have a mapping for C types or rules for what C type to use in your codegen or in ToFunction. Until you can see how many special cases there are that a CName function would help enough for. |
9df8d62
to
2a74281
Compare
OK I think this is ready for a review pass. This isn't complete work yet but I think might have enough of a bite for us to figure out what might go in. Severely needs more testing. |
return true | ||
} | ||
if _, ok := map[string]bool{ | ||
"CGDirectDisplayCopyCurrentMetalDevice": true, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we have reasons for why these are skipped in comments?
Tried running generate on appkit and with a few fixes it generates but then compiling a program gives a lot of these warnings now:
But more importantly, these errors:
Is this a known part of the process? Like is this something you know how to handle? |
Sorry missed this comment, not a known part of the process, my hope/intent was that once we have the structs appropriately defined with the same memory layout that this is just a cast. |
WIP functions support
copilot:walkthrough