I'm trying to free the memory after a large JSON object was created:

void createobject(){

Json jso = Json.emptyObject();
for(int i=0;i<1000000;i++){
   string str = format("Attrib #%d", i);
   jso[str] ="012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789";

}

}

I tried:

GC.collect();

and

destroy(jso);

to no avail.