| Index: runtime/vm/precompiler.cc
|
| diff --git a/runtime/vm/precompiler.cc b/runtime/vm/precompiler.cc
|
| index c1bf705fe8fed0204a7d713793612f9cec60b8b7..56e4ffc0dcfe396c9490299450a8e5b0b4521fa8 100644
|
| --- a/runtime/vm/precompiler.cc
|
| +++ b/runtime/vm/precompiler.cc
|
| @@ -742,26 +742,24 @@ void Precompiler::DropUncompiledFunctions() {
|
| functions.SetAt(j, function);
|
| }
|
| cls.SetFunctions(functions);
|
| + }
|
| + }
|
|
|
| - closures = cls.closures();
|
| - if (!closures.IsNull()) {
|
| - retained_functions = GrowableObjectArray::New();
|
| - for (intptr_t j = 0; j < closures.Length(); j++) {
|
| - function ^= closures.At(j);
|
| - if (function.HasCode()) {
|
| - retained_functions.Add(function);
|
| - } else {
|
| - dropped_function_count_++;
|
| - if (FLAG_trace_precompiler) {
|
| - THR_Print("Precompilation dropping %s\n",
|
| - function.ToLibNamePrefixedQualifiedCString());
|
| - }
|
| - }
|
| - }
|
| - cls.set_closures(retained_functions);
|
| + closures = isolate()->object_store()->closure_functions();
|
| + retained_functions = GrowableObjectArray::New();
|
| + for (intptr_t j = 0; j < closures.Length(); j++) {
|
| + function ^= closures.At(j);
|
| + if (function.HasCode()) {
|
| + retained_functions.Add(function);
|
| + } else {
|
| + dropped_function_count_++;
|
| + if (FLAG_trace_precompiler) {
|
| + THR_Print("Precompilation dropping %s\n",
|
| + function.ToLibNamePrefixedQualifiedCString());
|
| }
|
| }
|
| }
|
| + isolate()->object_store()->set_closure_functions(retained_functions);
|
| }
|
|
|
|
|
| @@ -894,16 +892,13 @@ void Precompiler::VisitFunctions(FunctionVisitor* visitor) {
|
| visitor->VisitFunction(function);
|
| }
|
| }
|
| -
|
| - closures = cls.closures();
|
| - if (!closures.IsNull()) {
|
| - for (intptr_t j = 0; j < closures.Length(); j++) {
|
| - function ^= closures.At(j);
|
| - visitor->VisitFunction(function);
|
| - }
|
| - }
|
| }
|
| }
|
| + closures = isolate()->object_store()->closure_functions();
|
| + for (intptr_t j = 0; j < closures.Length(); j++) {
|
| + function ^= closures.At(j);
|
| + visitor->VisitFunction(function);
|
| + }
|
| }
|
|
|
|
|
|
|