diff options
| author | Juan Linietsky | 2014-12-16 22:31:57 -0300 |
|---|---|---|
| committer | Juan Linietsky | 2014-12-16 22:31:57 -0300 |
| commit | bcf27feb980aec593c7cb771984e46113cfad757 (patch) | |
| tree | dabc98af627732ccf5d1bbfa8aa58348030f6324 /modules/gdscript/gd_compiler.cpp | |
| parent | be4e40e90a5a322f6a7cec4893854ef5b15db600 (diff) | |
| download | godot-bcf27feb980aec593c7cb771984e46113cfad757.tar.gz godot-bcf27feb980aec593c7cb771984e46113cfad757.tar.zst godot-bcf27feb980aec593c7cb771984e46113cfad757.zip | |
Diffstat (limited to 'modules/gdscript/gd_compiler.cpp')
| -rw-r--r-- | modules/gdscript/gd_compiler.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/modules/gdscript/gd_compiler.cpp b/modules/gdscript/gd_compiler.cpp index 5595db95d..d4fe8b626 100644 --- a/modules/gdscript/gd_compiler.cpp +++ b/modules/gdscript/gd_compiler.cpp @@ -1168,6 +1168,7 @@ Error GDCompiler::_parse_function(GDScript *p_script,const GDParser::ClassNode * codegen.current_line=0; codegen.call_max=0; codegen.debug_stack=ScriptDebugger::get_singleton()!=NULL; + Vector<StringName> argnames; int stack_level=0; @@ -1175,6 +1176,9 @@ Error GDCompiler::_parse_function(GDScript *p_script,const GDParser::ClassNode * for(int i=0;i<p_func->arguments.size();i++) { int idx = i; codegen.add_stack_identifier(p_func->arguments[i],i); +#ifdef TOOLS_ENABLED + argnames.push_back(p_func->arguments[i]); +#endif } stack_level=p_func->arguments.size(); } @@ -1249,6 +1253,9 @@ Error GDCompiler::_parse_function(GDScript *p_script,const GDParser::ClassNode * if (p_func) gdfunc->_static=p_func->_static; +#ifdef TOOLS_ENABLED + gdfunc->arg_names=argnames; +#endif //constants if (codegen.constant_map.size()) { gdfunc->_constant_count=codegen.constant_map.size(); |
