-
Notifications
You must be signed in to change notification settings - Fork 520
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
Fix/bootstrap update #1904
base: main
Are you sure you want to change the base?
Fix/bootstrap update #1904
Conversation
@tritao I'll just leave this here since then I can provide a bit of context. I've made these changes when I was working on this and just converted them into individual PR's. |
Also, I've continued using the 'old' method here, but I assume we could also update the bootstrap source generator to use the newer methods right? |
450c4a9
to
172b319
Compare
Can you clarify what you mean by this? |
Yeah I mean like the way types are mapped, ignored and renamed and such. |
Btw, I have a question about the requirements on generated source. What promises are we making about the language version of the generated source? I kinda want to look into modernizing the output (like inline field initialization instead of using a constructor, which can then be marked |
Ah yes, I see what you mean now. I guess both approaches can have their pros/cons, but if you think the other approach is preferable and more readable here, feel free to go for it. And overall really amazing work on this, everything looks great, think it should be ready to merge when all the dependencies are in. |
There is no formal promise I guess, but if it compiles in the supported CI environments, then it should be fine. Windows CI action is on 17.12.35707.178, which seems to be pretty recent. Personally I am not on using Windows lately, but it would probably be reasonable to keep compatibility with a somewhat older release too. |
@tritao So quick question; Can I convert Seems like it would avoid many of the issues we're facing now |
I think that would be great, I don't think it was available at the time that code was written, so we had to come up with our own traversing solution, but nowadays re-using Clang's would definitely be the way to go. |
Awesome, thought as much. I'll get on that then :) |
Also now that we have the bootstrap tool up-to-date, I wonder if it could be used to also generate the code for using |
Yeah, I was thinking the same. But I think I'll first get it working by coding it manually and then see if there's a way to generate that |
Okay, I'll change that plan a bit. I've made a start now and have a plan of attack so I know what I need/want. I think I'll just get commit #1900 working with a small compromise and then get this PR merged as well. That should allow me to at least work with that updated. Then I might just generate some of that code to reduce the workload. I think what I should do then, is first get the current version fully auto generated and then get to the AST node traverser update (since it's quite a bit of code to write XD) |
36a5157
to
1ac1add
Compare
Is this ready to go now? |
No not quite. I noticed there's a build error that didn't popup locally. It's because CI builds the csharp bindings while local windows uses c++/cli. For the past 3 days I was working on getting that fixed, but I'm having trouble with getting those bindings to generate properly. |
I would be fine with just switching everything to C# bindings, if that makes it any easier. |
No it's the other way around. The c++/cli code works great, but the c# p/invoke (std) bindings have build errors currently
|
637e43c
to
f600234
Compare
f600234
to
67aabd0
Compare
Update bootstrap / parser gen lang version
67aabd0
to
a2f5b3b
Compare
f990cd5
to
de6fec4
Compare
11e75d8
to
eb3c54a
Compare
Depends on these PRs to fix the bootstrap codegen:
TemplateTypeParm
decl #1901std::optional
<=>System::Nullable
#1902Note that these are included in the current PR. I'll rebase this PR and remove the draft marker once each is merged