Index: src/compiler.h |
diff --git a/src/compiler.h b/src/compiler.h |
index e8beca5a05a68f2230108bec4127c16f5ef189f1..ed461b41f55fe5b82fd66a40d3389b27b46bd3f2 100644 |
--- a/src/compiler.h |
+++ b/src/compiler.h |
@@ -82,12 +82,14 @@ class CompilationInfo { |
Handle<JSFunction> closure() const { return closure_; } |
Handle<SharedFunctionInfo> shared_info() const { return shared_info_; } |
Handle<Script> script() const { return script_; } |
+ void set_script(Handle<Script> script) { script_ = script; } |
HydrogenCodeStub* code_stub() const {return code_stub_; } |
v8::Extension* extension() const { return extension_; } |
ScriptData** cached_data() const { return cached_data_; } |
ScriptCompiler::CompileOptions compile_options() const { |
return compile_options_; |
} |
+ ExternalSourceStream* source_stream() const { return source_stream_; } |
Handle<Context> context() const { return context_; } |
BailoutId osr_ast_id() const { return osr_ast_id_; } |
Handle<Code> unoptimized_code() const { return unoptimized_code_; } |
@@ -373,6 +375,9 @@ class CompilationInfo { |
CompilationInfo(HydrogenCodeStub* stub, |
Isolate* isolate, |
Zone* zone); |
+ CompilationInfo(ExternalSourceStream* source_stream, Isolate* isolate, |
+ Zone* zone); |
+ |
private: |
Isolate* isolate_; |
@@ -450,6 +455,7 @@ class CompilationInfo { |
Handle<JSFunction> closure_; |
Handle<SharedFunctionInfo> shared_info_; |
Handle<Script> script_; |
+ ExternalSourceStream* source_stream_; |
// Fields possibly needed for eager compilation, NULL by default. |
v8::Extension* extension_; |
@@ -529,6 +535,9 @@ class CompilationInfoWithZone: public CompilationInfo { |
explicit CompilationInfoWithZone(Handle<JSFunction> closure) |
: CompilationInfo(closure, &zone_), |
zone_(closure->GetIsolate()) {} |
+ explicit CompilationInfoWithZone(ExternalSourceStream* stream, |
+ Isolate* isolate) |
+ : CompilationInfo(stream, isolate, &zone_), zone_(isolate) {} |
CompilationInfoWithZone(HydrogenCodeStub* stub, Isolate* isolate) |
: CompilationInfo(stub, isolate, &zone_), |
zone_(isolate) {} |
@@ -691,6 +700,9 @@ class Compiler : public AllStatic { |
ScriptCompiler::CompileOptions compile_options, |
NativesFlag is_natives_code); |
+ static Handle<SharedFunctionInfo> CompileStreamedScript(CompilationInfo* info, |
+ int source_length); |
+ |
// Create a shared function info object (the code may be lazily compiled). |
static Handle<SharedFunctionInfo> BuildFunctionInfo(FunctionLiteral* node, |
Handle<Script> script, |
@@ -714,6 +726,9 @@ class Compiler : public AllStatic { |
static void RecordFunctionCompilation(Logger::LogEventsAndTags tag, |
CompilationInfo* info, |
Handle<SharedFunctionInfo> shared); |
+ |
+ static bool DebuggerWantsEagerCompilation( |
+ CompilationInfo* info, bool allow_lazy_without_ctx = false); |
}; |