-
-
Notifications
You must be signed in to change notification settings - Fork 596
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
Uses StringName
in GDExtension perf critical instance creation & method/properties setter/getter
#896
Uses StringName
in GDExtension perf critical instance creation & method/properties setter/getter
#896
Conversation
a8f9c55
to
52bbbaa
Compare
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.
Looks really good.
A few missing things:
_alloc_and_copy_cstr
helper functions can be removed fromwrapper.hpp
,class_db.hpp
andmethod_bind.hpp
.- There's
GDNativeExtensionScriptInstanceToString
which is defined to returnconst char *
, but in the engine its return is assigned toString
, probably should be changed as well. - Also, you have missed
__constant_get_bitfield_name
(in thetype_info.hpp
).
@bruvzg thanks for the quick feedbacks 😃 I've updated the PR with your remarks |
c368bde
to
40d2e45
Compare
@bruvzg While I'm at at it, I wonder why in Godot the I suspect this is not really intended, but it creates the impression two instances of the same script can have different property/methods. I think it's a good thing to consider a script can never change once loaded (this is the kind of assertion that is expected, so you can be sure plenty of things will break in subtile way if an extension starts to do that) So my guess is we should correct this (or at least add comment on |
0f06f94
to
4b815a1
Compare
This PR is running fine with the demo project, so I guess this is ready for review & merge \o/ |
a698181
to
feadd9a
Compare
I think it's a bind for the |
…thod/properties setter/getter
feadd9a
to
b6ba0dc
Compare
@touilleMan I believe this PR might have caused #921 to happen. Could you confirm whether it's likely ? |
@groud that's most likely the case ! I'll try to have an eye on this before our Thursday meeting 🤠 |
related to godotengine/godot#67750