| Index: src/runtime.cc
|
| diff --git a/src/runtime.cc b/src/runtime.cc
|
| index 857339db66d947282e58d237c15ab07982620f91..b4abe88cbf910f6f997d63386b08c5d449b58a59 100644
|
| --- a/src/runtime.cc
|
| +++ b/src/runtime.cc
|
| @@ -8108,6 +8108,15 @@ RUNTIME_FUNCTION(MaybeObject*, Runtime_LazyRecompile) {
|
| HandleScope scope(isolate);
|
| ASSERT(args.length() == 1);
|
| Handle<JSFunction> function = args.at<JSFunction>(0);
|
| +
|
| + // If the function is not compiled ignore the lazy
|
| + // recompilation. This can happen if the debugger is activated and
|
| + // the function is returned to the not compiled state.
|
| + if (!function->shared()->is_compiled()) {
|
| + function->ReplaceCode(function->shared()->code());
|
| + return function->code();
|
| + }
|
| +
|
| // If the function is not optimizable or debugger is active continue using the
|
| // code from the full compiler.
|
| if (!function->shared()->code()->optimizable() ||
|
|
|