Both Array and Dictionary are always in shared mode (removed copy on write).

This commit is contained in:
Juan Linietsky
2017-01-11 08:53:31 -03:00
parent 57166cd292
commit e6583117df
17 changed files with 50 additions and 93 deletions

View File

@ -288,7 +288,7 @@ Error JSON::_parse_value(Variant &value,Token& token,const CharType *p_str,int &
if (token.type==TK_CURLY_BRACKET_OPEN) {
Dictionary d(true);
Dictionary d;
Error err = _parse_object(d,p_str,index,p_len,line,r_err_str);
if (err)
return err;
@ -296,7 +296,7 @@ Error JSON::_parse_value(Variant &value,Token& token,const CharType *p_str,int &
return OK;
} else if (token.type==TK_BRACKET_OPEN) {
Array a(true);
Array a;
Error err = _parse_array(a,p_str,index,p_len,line,r_err_str);
if (err)
return err;