You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Use hash table for GDScript parsing
GDScript now uses hash table for lookup of type lists / functions / keywords, instead of linear String comparisons.
This commit is contained in:
@@ -2095,6 +2095,8 @@ GDScriptWarning::Code GDScriptWarning::get_code_from_name(const String &p_name)
|
||||
#endif // DEBUG_ENABLED
|
||||
|
||||
GDScriptLanguage::GDScriptLanguage() {
|
||||
GDScriptTokenizer::initialize();
|
||||
|
||||
calls = 0;
|
||||
ERR_FAIL_COND(singleton);
|
||||
singleton = this;
|
||||
@@ -2139,6 +2141,8 @@ GDScriptLanguage::GDScriptLanguage() {
|
||||
}
|
||||
|
||||
GDScriptLanguage::~GDScriptLanguage() {
|
||||
GDScriptTokenizer::terminate();
|
||||
|
||||
if (_call_stack) {
|
||||
memdelete_arr(_call_stack);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user