| Index: src/accessors.cc
|
| diff --git a/src/accessors.cc b/src/accessors.cc
|
| index 54bd241b8d639fe70e8d82cc826e48b52477b5c4..a07b8df568ac76c760572e1fa0d4fb8ca5b85e5d 100644
|
| --- a/src/accessors.cc
|
| +++ b/src/accessors.cc
|
| @@ -587,6 +587,77 @@ Handle<AccessorInfo> Accessors::ScriptLineEndsInfo(
|
|
|
|
|
| //
|
| +// Accessors::ScriptSourceUrl
|
| +//
|
| +
|
| +
|
| +void Accessors::ScriptSourceUrlGetter(
|
| + v8::Local<v8::String> 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());
|
| + Object* url = Script::cast(JSValue::cast(object)->value())->source_url();
|
| + info.GetReturnValue().Set(Utils::ToLocal(Handle<Object>(url, isolate)));
|
| +}
|
| +
|
| +
|
| +void Accessors::ScriptSourceUrlSetter(
|
| + v8::Local<v8::String> name,
|
| + v8::Local<v8::Value> value,
|
| + const v8::PropertyCallbackInfo<void>& info) {
|
| + UNREACHABLE();
|
| +}
|
| +
|
| +
|
| +Handle<AccessorInfo> Accessors::ScriptSourceUrlInfo(
|
| + Isolate* isolate, PropertyAttributes attributes) {
|
| + return MakeAccessor(isolate,
|
| + isolate->factory()->source_url_string(),
|
| + &ScriptSourceUrlGetter,
|
| + &ScriptSourceUrlSetter,
|
| + attributes);
|
| +}
|
| +
|
| +
|
| +//
|
| +// Accessors::ScriptSourceMappingUrl
|
| +//
|
| +
|
| +
|
| +void Accessors::ScriptSourceMappingUrlGetter(
|
| + v8::Local<v8::String> 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());
|
| + Object* url =
|
| + Script::cast(JSValue::cast(object)->value())->source_mapping_url();
|
| + info.GetReturnValue().Set(Utils::ToLocal(Handle<Object>(url, isolate)));
|
| +}
|
| +
|
| +
|
| +void Accessors::ScriptSourceMappingUrlSetter(
|
| + v8::Local<v8::String> name,
|
| + v8::Local<v8::Value> value,
|
| + const v8::PropertyCallbackInfo<void>& info) {
|
| + UNREACHABLE();
|
| +}
|
| +
|
| +
|
| +Handle<AccessorInfo> Accessors::ScriptSourceMappingUrlInfo(
|
| + Isolate* isolate, PropertyAttributes attributes) {
|
| + return MakeAccessor(isolate,
|
| + isolate->factory()->source_mapping_url_string(),
|
| + &ScriptSourceMappingUrlGetter,
|
| + &ScriptSourceMappingUrlSetter,
|
| + attributes);
|
| +}
|
| +
|
| +
|
| +//
|
| // Accessors::ScriptGetContextData
|
| //
|
|
|
|
|