| Index: runtime/vm/compiler.cc
|
| diff --git a/runtime/vm/compiler.cc b/runtime/vm/compiler.cc
|
| index 8f06434fe7ec1c4f97cf93c7cd5638996af4a081..41a32c583bdae2baadbf7c30bac8af5d89a9121a 100644
|
| --- a/runtime/vm/compiler.cc
|
| +++ b/runtime/vm/compiler.cc
|
| @@ -1595,8 +1595,12 @@ void Compiler::ComputeLocalVarDescriptors(const Code& code) {
|
| // if state changed while compiling in background.
|
| LongJumpScope jump;
|
| if (setjmp(*jump.Set()) == 0) {
|
| - Parser::ParseFunction(parsed_function);
|
| - parsed_function->AllocateVariables();
|
| + if (function.kernel_function() == NULL) {
|
| + Parser::ParseFunction(parsed_function);
|
| + parsed_function->AllocateVariables();
|
| + } else {
|
| + parsed_function->EnsureKernelScopes();
|
| + }
|
| const LocalVarDescriptors& var_descs = LocalVarDescriptors::Handle(
|
| parsed_function->node_sequence()->scope()->GetVarDescriptors(function));
|
| ASSERT(!var_descs.IsNull());
|
|
|