Age | Commit message (Collapse) | Author |
|
Use pointer parameters in Variant function pointers
|
|
GDScript: Refactor builtin functions
|
|
Instead of references. This is needed because those function pointers
are used in GDNative which needs to work with plain C, which doesn't
support passing parameters by reference.
|
|
- Initialize Object pointer to nullptr so it's not used by mistake.
- When setting an Object check if it's a reference so refcounting works
as intended.
|
|
They are now called "utility functions" to avoid confusion with methods
of builtin types, and be consistent with the naming in Variant.
Core utility functions are now available in GDScript. The ones missing
in core are added specifically to GDScript as helpers for convenience.
Some functions were remove when there are better ways to do, reducing
redundancy and cleaning up the global scope.
|
|
Only for built-in types.
|
|
|
|
Methods from builtin types can be called by using the function pointer
when the argument and base types are known at compile time.
|
|
|
|
When the base type is known at compile-time, we can get a direct
function pointer that is faster than the regular set/get paths.
|
|
It now uses the direct operator function pointer, which increases
performance in evaluation.
|
|
Almost all instructions need variant arguments. With this change they
are loaded in an array before each instruction call. This makes the
addressing code be localized to less places, improving compilation
overhead and binary size by a small margin.
This should not affect performance.
|
|
To improve organization and reduce the size of compilation units.
|