Handle<Integer> resource_line_offset = Handle<Integer>(),
Handle<Integer> resource_column_offset = Handle<Integer>(),
Handle<Boolean> resource_is_shared_cross_origin = Handle<Boolean>(),
- Handle<Integer> script_id = Handle<Integer>())
+ Handle<Integer> script_id = Handle<Integer>(),
+ Handle<Boolean> resource_is_embedder_debug_script = Handle<Boolean>())
: resource_name_(resource_name),
resource_line_offset_(resource_line_offset),
resource_column_offset_(resource_column_offset),
+ resource_is_embedder_debug_script_(resource_is_embedder_debug_script),
resource_is_shared_cross_origin_(resource_is_shared_cross_origin),
- script_id_(script_id) { }
+ script_id_(script_id) {}
V8_INLINE Handle<Value> ResourceName() const;
V8_INLINE Handle<Integer> ResourceLineOffset() const;
V8_INLINE Handle<Integer> ResourceColumnOffset() const;
+ /**
+ * Returns true for embedder's debugger scripts
+ */
+ V8_INLINE Handle<Boolean> ResourceIsEmbedderDebugScript() const;
V8_INLINE Handle<Boolean> ResourceIsSharedCrossOrigin() const;
V8_INLINE Handle<Integer> ScriptID() const;
+
private:
Handle<Value> resource_name_;
Handle<Integer> resource_line_offset_;
Handle<Integer> resource_column_offset_;
+ Handle<Boolean> resource_is_embedder_debug_script_;
Handle<Boolean> resource_is_shared_cross_origin_;
Handle<Integer> script_id_;
};
Handle<Value> resource_name;
Handle<Integer> resource_line_offset;
Handle<Integer> resource_column_offset;
+ Handle<Boolean> resource_is_embedder_debug_script;
Handle<Boolean> resource_is_shared_cross_origin;
// Cached data from previous compilation (if a kConsume*Cache flag is
}
+Handle<Boolean> ScriptOrigin::ResourceIsEmbedderDebugScript() const {
+ return resource_is_embedder_debug_script_;
+}
+
+
Handle<Boolean> ScriptOrigin::ResourceIsSharedCrossOrigin() const {
return resource_is_shared_cross_origin_;
}
resource_name(origin.ResourceName()),
resource_line_offset(origin.ResourceLineOffset()),
resource_column_offset(origin.ResourceColumnOffset()),
+ resource_is_embedder_debug_script(origin.ResourceIsEmbedderDebugScript()),
resource_is_shared_cross_origin(origin.ResourceIsSharedCrossOrigin()),
cached_data(data) {}
//
+// Accessors::ScriptIsEmbedderDebugScript
+//
+
+
+void Accessors::ScriptIsEmbedderDebugScriptGetter(
+ v8::Local<v8::Name> name, const v8::PropertyCallbackInfo<v8::Value>& info) {
+ i::Isolate* isolate = reinterpret_cast<i::Isolate*>(info.GetIsolate());
+ DisallowHeapAllocation no_allocation;
+ HandleScope scope(isolate);
+ Object* object = *Utils::OpenHandle(*info.This());
+ bool is_embedder_debug_script =
+ Script::cast(JSValue::cast(object)->value())->is_embedder_debug_script();
+ Object* res = *isolate->factory()->ToBoolean(is_embedder_debug_script);
+ info.GetReturnValue().Set(Utils::ToLocal(Handle<Object>(res, isolate)));
+}
+
+
+void Accessors::ScriptIsEmbedderDebugScriptSetter(
+ v8::Local<v8::Name> name, v8::Local<v8::Value> value,
+ const v8::PropertyCallbackInfo<void>& info) {
+ UNREACHABLE();
+}
+
+
+Handle<AccessorInfo> Accessors::ScriptIsEmbedderDebugScriptInfo(
+ Isolate* isolate, PropertyAttributes attributes) {
+ Handle<String> name(isolate->factory()->InternalizeOneByteString(
+ STATIC_CHAR_VECTOR("is_debugger_script")));
+ return MakeAccessor(isolate, name, &ScriptIsEmbedderDebugScriptGetter,
+ &ScriptIsEmbedderDebugScriptSetter, attributes);
+}
+
+
+//
// Accessors::ScriptGetContextData
//
V(ScriptType) \
V(ScriptSourceUrl) \
V(ScriptSourceMappingUrl) \
+ V(ScriptIsEmbedderDebugScript) \
V(StringLength)
// Accessors contains all predefined proxy accessors.
i::Handle<i::Object> name_obj;
int line_offset = 0;
int column_offset = 0;
+ bool is_embedder_debug_script = false;
bool is_shared_cross_origin = false;
if (!source->resource_name.IsEmpty()) {
name_obj = Utils::OpenHandle(*(source->resource_name));
static_cast<int>(source->resource_column_offset->Value());
}
if (!source->resource_is_shared_cross_origin.IsEmpty()) {
- v8::Isolate* v8_isolate = reinterpret_cast<v8::Isolate*>(isolate);
is_shared_cross_origin =
- source->resource_is_shared_cross_origin == v8::True(v8_isolate);
+ source->resource_is_shared_cross_origin->IsTrue();
+ }
+ if (!source->resource_is_embedder_debug_script.IsEmpty()) {
+ is_embedder_debug_script =
+ source->resource_is_embedder_debug_script->IsTrue();
}
EXCEPTION_PREAMBLE(isolate);
i::Handle<i::SharedFunctionInfo> result = i::Compiler::CompileScript(
- str, name_obj, line_offset, column_offset, is_shared_cross_origin,
- isolate->native_context(), NULL, &script_data, options,
- i::NOT_NATIVES_CODE);
+ str, name_obj, line_offset, column_offset, is_embedder_debug_script,
+ is_shared_cross_origin, isolate->native_context(), NULL, &script_data,
+ options, i::NOT_NATIVES_CODE);
has_pending_exception = result.is_null();
if (has_pending_exception && script_data != NULL) {
// This case won't happen during normal operation; we have compiled
static_cast<int>(origin.ResourceColumnOffset()->Value())));
}
if (!origin.ResourceIsSharedCrossOrigin().IsEmpty()) {
- script->set_is_shared_cross_origin(origin.ResourceIsSharedCrossOrigin() ==
- v8::True(v8_isolate));
+ script->set_is_shared_cross_origin(
+ origin.ResourceIsSharedCrossOrigin()->IsTrue());
+ }
+ if (!origin.ResourceIsEmbedderDebugScript().IsEmpty()) {
+ script->set_is_embedder_debug_script(
+ origin.ResourceIsEmbedderDebugScript()->IsTrue());
}
source->info->set_script(script);
source->info->SetContext(isolate->native_context());
Utils::ToLocal(scriptName),
v8::Integer::New(v8_isolate, script->line_offset()->value()),
v8::Integer::New(v8_isolate, script->column_offset()->value()),
- Handle<Boolean>(),
- v8::Integer::New(v8_isolate, script->id()->value()));
+ v8::Boolean::New(v8_isolate, script->is_shared_cross_origin()),
+ v8::Integer::New(v8_isolate, script->id()->value()),
+ v8::Boolean::New(v8_isolate, script->is_embedder_debug_script()));
return origin;
}
v8::ScriptOrigin origin(
Utils::ToLocal(scriptName),
v8::Integer::New(isolate, script->line_offset()->value()),
- v8::Integer::New(isolate, script->column_offset()->value()));
+ v8::Integer::New(isolate, script->column_offset()->value()),
+ v8::Boolean::New(isolate, script->is_shared_cross_origin()),
+ v8::Integer::New(isolate, script->id()->value()),
+ v8::Boolean::New(isolate, script->is_embedder_debug_script()));
return origin;
}
return v8::ScriptOrigin(Handle<Value>());
Handle<String> script_name =
factory->NewStringFromUtf8(name).ToHandleChecked();
function_info = Compiler::CompileScript(
- source, script_name, 0, 0, false, top_context, extension, NULL,
+ source, script_name, 0, 0, false, false, top_context, extension, NULL,
ScriptCompiler::kNoCompileOptions,
use_runtime_context ? NATIVES_CODE : NOT_NATIVES_CODE);
if (function_info.is_null()) return false;
native_context()->set_script_function(*script_fun);
Handle<Map> script_map = Handle<Map>(script_fun->initial_map());
- Map::EnsureDescriptorSlack(script_map, 14);
+ Map::EnsureDescriptorSlack(script_map, 15);
PropertyAttributes attribs =
static_cast<PropertyAttributes>(DONT_ENUM | DONT_DELETE | READ_ONLY);
script_map->AppendDescriptor(&d);
}
+ Handle<AccessorInfo> script_is_embedder_debug_script =
+ Accessors::ScriptIsEmbedderDebugScriptInfo(isolate(), attribs);
+ {
+ AccessorConstantDescriptor d(
+ Handle<Name>(Name::cast(script_is_embedder_debug_script->name())),
+ script_is_embedder_debug_script, attribs);
+ script_map->AppendDescriptor(&d);
+ }
+
// Allocate the empty script.
Handle<Script> script = factory()->NewScript(factory()->empty_string());
script->set_type(Smi::FromInt(Script::TYPE_NATIVE));
// We only re-use a cached function for some script source code if the
// script originates from the same place. This is to avoid issues
// when reporting errors, etc.
-bool CompilationCacheScript::HasOrigin(
- Handle<SharedFunctionInfo> function_info,
- Handle<Object> name,
- int line_offset,
- int column_offset,
- bool is_shared_cross_origin) {
+bool CompilationCacheScript::HasOrigin(Handle<SharedFunctionInfo> function_info,
+ Handle<Object> name, int line_offset,
+ int column_offset,
+ bool is_embedder_debug_script,
+ bool is_shared_cross_origin) {
Handle<Script> script =
Handle<Script>(Script::cast(function_info->script()), isolate());
// If the script name isn't set, the boilerplate script should have
if (column_offset != script->column_offset()->value()) return false;
// Check that both names are strings. If not, no match.
if (!name->IsString() || !script->name()->IsString()) return false;
+ // Were both scripts tagged by the embedder as being internal script?
+ if (is_embedder_debug_script != script->is_embedder_debug_script()) {
+ return false;
+ }
// Were both scripts tagged by the embedder as being shared cross-origin?
if (is_shared_cross_origin != script->is_shared_cross_origin()) return false;
// Compare the two name strings for equality.
// will be cached, but subsequent code from different source / line
// won't.
Handle<SharedFunctionInfo> CompilationCacheScript::Lookup(
- Handle<String> source,
- Handle<Object> name,
- int line_offset,
- int column_offset,
- bool is_shared_cross_origin,
- Handle<Context> context) {
+ Handle<String> source, Handle<Object> name, int line_offset,
+ int column_offset, bool is_embedder_debug_script,
+ bool is_shared_cross_origin, Handle<Context> context) {
Object* result = NULL;
int generation;
Handle<SharedFunctionInfo>::cast(probe);
// Break when we've found a suitable shared function info that
// matches the origin.
- if (HasOrigin(function_info,
- name,
- line_offset,
- column_offset,
- is_shared_cross_origin)) {
+ if (HasOrigin(function_info, name, line_offset, column_offset,
+ is_embedder_debug_script, is_shared_cross_origin)) {
result = *function_info;
break;
}
if (result != NULL) {
Handle<SharedFunctionInfo> shared(SharedFunctionInfo::cast(result),
isolate());
- DCHECK(HasOrigin(shared,
- name,
- line_offset,
- column_offset,
- is_shared_cross_origin));
+ DCHECK(HasOrigin(shared, name, line_offset, column_offset,
+ is_embedder_debug_script, is_shared_cross_origin));
// If the script was found in a later generation, we promote it to
// the first generation to let it survive longer in the cache.
if (generation != 0) Put(source, context, shared);
MaybeHandle<SharedFunctionInfo> CompilationCache::LookupScript(
- Handle<String> source,
- Handle<Object> name,
- int line_offset,
- int column_offset,
- bool is_shared_cross_origin,
- Handle<Context> context) {
+ Handle<String> source, Handle<Object> name, int line_offset,
+ int column_offset, bool is_embedder_debug_script,
+ bool is_shared_cross_origin, Handle<Context> context) {
if (!IsEnabled()) return MaybeHandle<SharedFunctionInfo>();
return script_.Lookup(source, name, line_offset, column_offset,
- is_shared_cross_origin, context);
+ is_embedder_debug_script, is_shared_cross_origin,
+ context);
}
public:
CompilationCacheScript(Isolate* isolate, int generations);
- Handle<SharedFunctionInfo> Lookup(Handle<String> source,
- Handle<Object> name,
- int line_offset,
- int column_offset,
+ Handle<SharedFunctionInfo> Lookup(Handle<String> source, Handle<Object> name,
+ int line_offset, int column_offset,
+ bool is_embedder_debug_script,
bool is_shared_cross_origin,
Handle<Context> context);
void Put(Handle<String> source,
Handle<SharedFunctionInfo> function_info);
private:
- bool HasOrigin(Handle<SharedFunctionInfo> function_info,
- Handle<Object> name,
- int line_offset,
- int column_offset,
- bool is_shared_cross_origin);
+ bool HasOrigin(Handle<SharedFunctionInfo> function_info, Handle<Object> name,
+ int line_offset, int column_offset,
+ bool is_embedder_debug_script, bool is_shared_cross_origin);
DISALLOW_IMPLICIT_CONSTRUCTORS(CompilationCacheScript);
};
// script for the given source string with the right origin.
MaybeHandle<SharedFunctionInfo> LookupScript(
Handle<String> source, Handle<Object> name, int line_offset,
- int column_offset, bool is_shared_cross_origin, Handle<Context> context);
+ int column_offset, bool is_embedder_debug_script,
+ bool is_shared_cross_origin, Handle<Context> context);
// Finds the shared function info for a source string for eval in a
// given context. Returns an empty handle if the cache doesn't
Handle<SharedFunctionInfo> Compiler::CompileScript(
Handle<String> source, Handle<Object> script_name, int line_offset,
- int column_offset, bool is_shared_cross_origin, Handle<Context> context,
+ int column_offset, bool is_embedder_debug_script,
+ bool is_shared_cross_origin, Handle<Context> context,
v8::Extension* extension, ScriptData** cached_data,
ScriptCompiler::CompileOptions compile_options, NativesFlag natives) {
Isolate* isolate = source->GetIsolate();
Handle<SharedFunctionInfo> result;
if (extension == NULL) {
maybe_result = compilation_cache->LookupScript(
- source, script_name, line_offset, column_offset, is_shared_cross_origin,
- context);
+ source, script_name, line_offset, column_offset,
+ is_embedder_debug_script, is_shared_cross_origin, context);
if (maybe_result.is_null() && FLAG_serialize_toplevel &&
compile_options == ScriptCompiler::kConsumeCodeCache &&
!isolate->debug()->is_loaded()) {
script->set_column_offset(Smi::FromInt(column_offset));
}
script->set_is_shared_cross_origin(is_shared_cross_origin);
+ script->set_is_embedder_debug_script(is_embedder_debug_script);
// Compile the function and add it to the cache.
CompilationInfoWithZone info(script);
// Compile a String source within a context.
static Handle<SharedFunctionInfo> CompileScript(
Handle<String> source, Handle<Object> script_name, int line_offset,
- int column_offset, bool is_shared_cross_origin, Handle<Context> context,
- v8::Extension* extension, ScriptData** cached_data,
- ScriptCompiler::CompileOptions compile_options,
+ int column_offset, bool is_debugger_script, bool is_shared_cross_origin,
+ Handle<Context> context, v8::Extension* extension,
+ ScriptData** cached_data, ScriptCompiler::CompileOptions compile_options,
NativesFlag is_natives_code);
static Handle<SharedFunctionInfo> CompileStreamedScript(CompilationInfo* info,
// Compile the script.
Handle<SharedFunctionInfo> function_info;
function_info = Compiler::CompileScript(
- source_code, script_name, 0, 0, false, context, NULL, NULL,
+ source_code, script_name, 0, 0, false, false, context, NULL, NULL,
ScriptCompiler::kNoCompileOptions, NATIVES_CODE);
// Silently ignore stack overflows during compilation.
ACCESSORS_TO_SMI(Script, eval_from_instructions_offset,
kEvalFrominstructionsOffsetOffset)
ACCESSORS_TO_SMI(Script, flags, kFlagsOffset)
+BOOL_ACCESSORS(Script, flags, is_embedder_debug_script,
+ kIsEmbedderDebugScriptBit)
BOOL_ACCESSORS(Script, flags, is_shared_cross_origin, kIsSharedCrossOriginBit)
ACCESSORS(Script, source_url, Object, kSourceUrlOffset)
ACCESSORS(Script, source_mapping_url, Object, kSourceMappingUrlOffset)
inline CompilationState compilation_state();
inline void set_compilation_state(CompilationState state);
+ // [is_embedder_debug_script]: An opaque boolean set by the embedder via
+ // ScriptOrigin, and used by the embedder to make decisions about the
+ // script's origin. V8 just passes this through. Encoded in
+ // the 'flags' field.
+ DECL_BOOLEAN_ACCESSORS(is_embedder_debug_script)
+
// [is_shared_cross_origin]: An opaque boolean set by the embedder via
// ScriptOrigin, and used by the embedder to make decisions about the
// script's level of privilege. V8 just passes this through. Encoded in
// Bit positions in the flags field.
static const int kCompilationTypeBit = 0;
static const int kCompilationStateBit = 1;
- static const int kIsSharedCrossOriginBit = 2;
+ static const int kIsEmbedderDebugScriptBit = 2;
+ static const int kIsSharedCrossOriginBit = 3;
DISALLOW_IMPLICIT_CONSTRUCTORS(Script);
};
->NewStringFromUtf8(CStrVector(source))
.ToHandleChecked();
Handle<SharedFunctionInfo> shared_function = Compiler::CompileScript(
- source_code, Handle<String>(), 0, 0, false,
+ source_code, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, NULL,
v8::ScriptCompiler::kNoCompileOptions, NOT_NATIVES_CODE);
return isolate->factory()->NewFunctionFromSharedFunctionInfo(
static void check_message_3(v8::Handle<v8::Message> message,
v8::Handle<Value> data) {
CHECK(message->IsSharedCrossOrigin());
+ CHECK(message->GetScriptOrigin().ResourceIsSharedCrossOrigin()->Value());
+ CHECK(message->GetScriptOrigin().ResourceIsEmbedderDebugScript()->Value());
CHECK_EQ(6.75, message->GetScriptOrigin().ResourceName()->NumberValue());
message_received = true;
}
v8::V8::AddMessageListener(check_message_3);
LocalContext context;
v8::ScriptOrigin origin =
- v8::ScriptOrigin(v8_str("6.75"),
- v8::Integer::New(isolate, 1),
- v8::Integer::New(isolate, 2),
- v8::True(isolate));
+ v8::ScriptOrigin(v8_str("6.75"), v8::Integer::New(isolate, 1),
+ v8::Integer::New(isolate, 2), v8::True(isolate),
+ Handle<v8::Integer>(), v8::True(isolate));
v8::Handle<v8::Script> script = Script::Compile(v8_str("throw 'error'"),
&origin);
script->Run();
THREADED_TEST(ScriptOrigin) {
LocalContext env;
v8::HandleScope scope(env->GetIsolate());
- v8::ScriptOrigin origin =
- v8::ScriptOrigin(v8::String::NewFromUtf8(env->GetIsolate(), "test"));
+ v8::ScriptOrigin origin = v8::ScriptOrigin(
+ v8::String::NewFromUtf8(env->GetIsolate(), "test"),
+ v8::Integer::New(env->GetIsolate(), 1),
+ v8::Integer::New(env->GetIsolate(), 1), v8::True(env->GetIsolate()),
+ v8::Handle<v8::Integer>(), v8::True(env->GetIsolate()));
v8::Handle<v8::String> script = v8::String::NewFromUtf8(
env->GetIsolate(), "function f() {}\n\nfunction g() {}");
v8::Script::Compile(script, &origin)->Run();
v8::ScriptOrigin script_origin_f = f->GetScriptOrigin();
CHECK_EQ("test", *v8::String::Utf8Value(script_origin_f.ResourceName()));
- CHECK_EQ(0, script_origin_f.ResourceLineOffset()->Int32Value());
+ CHECK_EQ(1, script_origin_f.ResourceLineOffset()->Int32Value());
+ CHECK(script_origin_f.ResourceIsSharedCrossOrigin()->Value());
+ CHECK(script_origin_f.ResourceIsEmbedderDebugScript()->Value());
v8::ScriptOrigin script_origin_g = g->GetScriptOrigin();
CHECK_EQ("test", *v8::String::Utf8Value(script_origin_g.ResourceName()));
- CHECK_EQ(0, script_origin_g.ResourceLineOffset()->Int32Value());
+ CHECK_EQ(1, script_origin_g.ResourceLineOffset()->Int32Value());
+ CHECK(script_origin_g.ResourceIsSharedCrossOrigin()->Value());
+ CHECK(script_origin_g.ResourceIsEmbedderDebugScript()->Value());
}
Handle<String> source_code = isolate->factory()->NewStringFromUtf8(
CStrVector(source)).ToHandleChecked();
Handle<SharedFunctionInfo> shared_function = Compiler::CompileScript(
- source_code, Handle<String>(), 0, 0, false,
+ source_code, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, NULL,
v8::ScriptCompiler::kNoCompileOptions, NOT_NATIVES_CODE);
return isolate->factory()->NewFunctionFromSharedFunctionInfo(
// On first compilation, only a hash is inserted in the code cache. We can't
// find that value.
MaybeHandle<SharedFunctionInfo> info = compilation_cache->LookupScript(
- source, Handle<Object>(), 0, 0, true, native_context);
+ source, Handle<Object>(), 0, 0, false, true, native_context);
CHECK(info.is_null());
{
// On second compilation, the hash is replaced by a real cache entry mapping
// the source to the shared function info containing the code.
- info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, true,
- native_context);
+ info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, false,
+ true, native_context);
CHECK(!info.is_null());
heap->CollectAllGarbage(Heap::kNoGCFlags);
// On second compilation, the hash is replaced by a real cache entry mapping
// the source to the shared function info containing the code.
- info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, true,
- native_context);
+ info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, false,
+ true, native_context);
CHECK(!info.is_null());
while (!info.ToHandleChecked()->code()->IsOld()) {
heap->CollectAllGarbage(Heap::kNoGCFlags);
// Ensure code aging cleared the entry from the cache.
- info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, true,
- native_context);
+ info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, false,
+ true, native_context);
CHECK(info.is_null());
{
// On first compilation, only a hash is inserted in the code cache. We can't
// find that value.
- info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, true,
- native_context);
+ info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, false,
+ true, native_context);
CHECK(info.is_null());
for (int i = 0; i < CompilationCacheTable::kHashGenerations; i++) {
// If we aged the cache before caching the script, ensure that we didn't cache
// on next compilation.
- info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, true,
- native_context);
+ info = compilation_cache->LookupScript(source, Handle<Object>(), 0, 0, false,
+ true, native_context);
CHECK(info.is_null());
}
ScriptData* cache = NULL;
Handle<SharedFunctionInfo> orig = Compiler::CompileScript(
- orig_source, Handle<String>(), 0, 0, false,
+ orig_source, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kProduceCodeCache, NOT_NATIVES_CODE);
{
DisallowCompilation no_compile_expected(isolate);
copy = Compiler::CompileScript(
- copy_source, Handle<String>(), 0, 0, false,
+ copy_source, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kConsumeCodeCache, NOT_NATIVES_CODE);
}
ScriptData* cache = NULL;
Handle<SharedFunctionInfo> orig = Compiler::CompileScript(
- orig_source, Handle<String>(), 0, 0, false,
+ orig_source, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kProduceCodeCache, NOT_NATIVES_CODE);
Handle<JSFunction> orig_fun =
{
DisallowCompilation no_compile_expected(isolate);
copy = Compiler::CompileScript(
- copy_source, Handle<String>(), 0, 0, false,
+ copy_source, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kConsumeCodeCache, NOT_NATIVES_CODE);
}
ScriptData* cache = NULL;
Handle<SharedFunctionInfo> orig = Compiler::CompileScript(
- source_str, Handle<String>(), 0, 0, false,
+ source_str, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kProduceCodeCache, NOT_NATIVES_CODE);
{
DisallowCompilation no_compile_expected(isolate);
copy = Compiler::CompileScript(
- source_str, Handle<String>(), 0, 0, false,
+ source_str, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kConsumeCodeCache, NOT_NATIVES_CODE);
}
ScriptData* cache = NULL;
Handle<SharedFunctionInfo> orig = Compiler::CompileScript(
- source_str, Handle<String>(), 0, 0, false,
+ source_str, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kProduceCodeCache, NOT_NATIVES_CODE);
{
DisallowCompilation no_compile_expected(isolate);
copy = Compiler::CompileScript(
- source_str, Handle<String>(), 0, 0, false,
+ source_str, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kConsumeCodeCache, NOT_NATIVES_CODE);
}
ScriptData* cache = NULL;
Handle<SharedFunctionInfo> orig = Compiler::CompileScript(
- source_str, Handle<String>(), 0, 0, false,
+ source_str, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kProduceCodeCache, NOT_NATIVES_CODE);
{
DisallowCompilation no_compile_expected(isolate);
copy = Compiler::CompileScript(
- source_str, Handle<String>(), 0, 0, false,
+ source_str, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kConsumeCodeCache, NOT_NATIVES_CODE);
}
ScriptData* cache = NULL;
Handle<SharedFunctionInfo> orig = Compiler::CompileScript(
- source_string, Handle<String>(), 0, 0, false,
+ source_string, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kProduceCodeCache, NOT_NATIVES_CODE);
{
DisallowCompilation no_compile_expected(isolate);
copy = Compiler::CompileScript(
- source_string, Handle<String>(), 0, 0, false,
+ source_string, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kConsumeCodeCache, NOT_NATIVES_CODE);
}
ScriptData* cache = NULL;
Handle<SharedFunctionInfo> orig = Compiler::CompileScript(
- source_str, Handle<String>(), 0, 0, false,
+ source_str, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kProduceCodeCache, NOT_NATIVES_CODE);
{
DisallowCompilation no_compile_expected(isolate);
copy = Compiler::CompileScript(
- source_str, Handle<String>(), 0, 0, false,
+ source_str, Handle<String>(), 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kConsumeCodeCache, NOT_NATIVES_CODE);
}
ScriptData* cache = NULL;
Handle<SharedFunctionInfo> orig = Compiler::CompileScript(
- source_string, name, 0, 0, false,
+ source_string, name, 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kProduceCodeCache, NOT_NATIVES_CODE);
{
DisallowCompilation no_compile_expected(isolate);
copy = Compiler::CompileScript(
- source_string, name, 0, 0, false,
+ source_string, name, 0, 0, false, false,
Handle<Context>(isolate->native_context()), NULL, &cache,
v8::ScriptCompiler::kConsumeCodeCache, NOT_NATIVES_CODE);
}