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

Revert removal of GDNativeExtensionScriptInstanceInfo::get_property_type_func in GDExtension #68549

Conversation

touilleMan
Copy link
Member

@touilleMan touilleMan commented Nov 12, 2022

Reverting the change on GDNativeExtensionScriptInstanceInfo I made in #67750, I thought it would be simpler to have a similar interface between GDExtension and GDNativeExtensionScriptInstanceInfo, but after deeper investigation it turns out it is much better to have GDNativeExtensionScriptInstanceInfo being just a proxy over Godot's internal ScriptInstance.

Besides, by removing this function pointer, we had to do property list create/free each time we want to access type which is quadratic complexity :/ (and implementing a cache on this is complex given property can be dynamically modified)

@touilleMan touilleMan requested review from a team as code owners November 12, 2022 03:05
…ype_func in GDExtension

This function pointer is needed to stay close to internal Godot's ScriptInstance class.
Besides, by removing this function pointer, we had to do property list create/free each time
we want to access type which is quadratic complexity :/
@touilleMan touilleMan force-pushed the gdextension-revert-get_property_type_func-removal branch from fcf9f1e to 39c039a Compare November 12, 2022 03:18
@akien-mga akien-mga added this to the 4.0 milestone Nov 12, 2022
@akien-mga akien-mga merged commit 324106b into godotengine:master Nov 12, 2022
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants