mirror of
https://github.com/godotengine/godot.git
synced 2025-10-19 16:03:29 +00:00
Core: Fix JSON.{from,to}_native()
issues
This commit is contained in:
parent
bbc54692c0
commit
bd1a35ce9e
15 changed files with 1237 additions and 874 deletions
|
@ -3858,13 +3858,10 @@ static Error _lookup_symbol_from_base(const GDScriptParser::DataType &p_base, co
|
|||
return OK;
|
||||
}
|
||||
|
||||
for (int i = 0; i < Variant::VARIANT_MAX; i++) {
|
||||
Variant::Type t = Variant::Type(i);
|
||||
if (Variant::get_type_name(t) == p_symbol) {
|
||||
r_result.type = ScriptLanguage::LOOKUP_RESULT_CLASS;
|
||||
r_result.class_name = Variant::get_type_name(t);
|
||||
return OK;
|
||||
}
|
||||
if (Variant::get_type_by_name(p_symbol) < Variant::VARIANT_MAX) {
|
||||
r_result.type = ScriptLanguage::LOOKUP_RESULT_CLASS;
|
||||
r_result.class_name = p_symbol;
|
||||
return OK;
|
||||
}
|
||||
|
||||
if ("Variant" == p_symbol) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue