GDScript: Add support for variadic functions

This commit is contained in:
Danil Alexeev 2025-03-30 12:59:05 +03:00
parent 3b963ab8b6
commit ee121ef80e
No known key found for this signature in database
GPG key ID: 5A52F75A8679EC57
33 changed files with 416 additions and 65 deletions

View file

@ -456,6 +456,7 @@ private:
GDScript *_script = nullptr;
int _initial_line = 0;
int _argument_count = 0;
int _vararg_index = -1;
int _stack_size = 0;
int _instruction_args_size = 0;
@ -577,6 +578,7 @@ public:
_FORCE_INLINE_ StringName get_source() const { return source; }
_FORCE_INLINE_ GDScript *get_script() const { return _script; }
_FORCE_INLINE_ bool is_static() const { return _static; }
_FORCE_INLINE_ bool is_vararg() const { return _vararg_index >= 0; }
_FORCE_INLINE_ MethodInfo get_method_info() const { return method_info; }
_FORCE_INLINE_ int get_argument_count() const { return _argument_count; }
_FORCE_INLINE_ Variant get_rpc_config() const { return rpc_config; }