Index: src/parsing/parse-info.cc |
diff --git a/src/parsing/parse-info.cc b/src/parsing/parse-info.cc |
index dfec0610e1dc7d3300fcabd671d2b8a76fab94cc..6b8fdf5f0dbcf3143b976535b1b68f3969520d35 100644 |
--- a/src/parsing/parse-info.cc |
+++ b/src/parsing/parse-info.cc |
@@ -33,7 +33,9 @@ ParseInfo::ParseInfo(Zone* zone) |
ParseInfo::ParseInfo(Zone* zone, Handle<JSFunction> function) |
: ParseInfo(zone, Handle<SharedFunctionInfo>(function->shared())) { |
- set_context(Handle<Context>(function->context())); |
+ if (!function->context()->IsNativeContext()) { |
+ set_outer_scope_info(handle(function->context()->scope_info())); |
+ } |
} |
ParseInfo::ParseInfo(Zone* zone, Handle<SharedFunctionInfo> shared) |