Index: src/compiler.cc |
diff --git a/src/compiler.cc b/src/compiler.cc |
index 2b451501f02b3d01ef2462daf213ad518df75ed6..59c6a3693f796b484aa885837469a8a496ce256f 100644 |
--- a/src/compiler.cc |
+++ b/src/compiler.cc |
@@ -981,6 +981,9 @@ Handle<SharedFunctionInfo> Compiler::CompileScript( |
info.SetCachedData(cached_data, cached_data_mode); |
info.SetExtension(extension); |
info.SetContext(context); |
+ if (FLAG_serialize_toplevel && cached_data_mode == PRODUCE_CACHED_DATA) { |
+ info.PrepareForSerializing(); |
+ } |
if (FLAG_use_strict) info.SetStrictMode(STRICT); |
result = CompileToplevel(&info); |