-
-
Notifications
You must be signed in to change notification settings - Fork 217
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
SceneTree::call_group_flags expects i64 as flag, not GroupCallFlags #185
Comments
The problem is that these bitfield types are sometimes exposed as enums in the GDExtension JSON, and their parameter/return types use Examples where the bitfield type is used (search There are also interesting cases that look like bitfields, but are not:
There may also be situations where a type is correctly marked as bitfield, but still used as I don't know how to easily detect that an enum is a bitfield, or that an
|
To be honest, this does feel like an upstream issue that we can do very little about, without facing increasing headaches. For the If we were to manually annotate, I think we'd have to mark it behind a compatibility flag of sorts, since the extension API can change, and cause issues for these specific edge-cases way down the line. 🙁 We could maybe do the heuristics approach by looking at each value and seeing if it's a Actually we can't since I don't think we can even look for enums that end with I really don't see a good way to solve this from our side. Also, why are these things so inconsistent in the first place?! 😭 |
SceneTree's method
call_group_flags
expects i64 as a flag, not the GroupCallFlags struct. Also, "ord" field is i32, not i64.It's working, but syntax is not very obvious:
The text was updated successfully, but these errors were encountered: