Use noexcept
modifier where it's possible to improve engine performance
#3302
Labels
noexcept
modifier where it's possible to improve engine performance
#3302
Describe the project you are working on
Godot
Describe the problem or limitation you are having in your project
No, it just can improve the engine performance.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
noexcept
is a C++ 11 feature (https://en.cppreference.com/w/cpp/language/noexcept) that can significantly increase the code performance due to enabling compile optimization by omitting the internal exception checking. Since Godot already does not have any exception handling by telling the compiler to not check it internally I think the result will be significantly better.See also a discussion about it: https://stackoverflow.com/questions/10787766/when-should-i-really-use-noexcept
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
By adding
noexcept
definition to all function declarations/definitions, constructors and operators (excluding third-party code of course). Probably that should perform automatically using some tool.If this enhancement will not be used often, can it be worked around with a few lines of script?
No
Is there a reason why this should be core and not an add-on in the asset library?
It's a core thing by default
The text was updated successfully, but these errors were encountered: